Lines Matching refs:item

40 static bool cache_defer_req(struct cache_req *req, struct cache_head *item);
41 static void cache_revisit_request(struct cache_head *item);
285 * It checks the currency of a cache item and will (later)
292 * upcall completed but item is still invalid (implying that
293 * the cache item has been replaced with a newer one).
574 #define DFR_HASH(item) ((((long)item)>>4 ^ (((long)item)>>13)) % DFR_HASHSIZE)
592 static void __hash_deferred_req(struct cache_deferred_req *dreq, struct cache_head *item)
594 int hash = DFR_HASH(item);
601 struct cache_head *item,
605 dreq->item = item;
609 __hash_deferred_req(dreq, item);
632 static void cache_wait_req(struct cache_req *req, struct cache_head *item)
640 setup_deferral(dreq, item, 0);
642 if (!test_bit(CACHE_PENDING, &item->flags) ||
692 static bool cache_defer_req(struct cache_req *req, struct cache_head *item)
697 cache_wait_req(req, item);
698 if (!test_bit(CACHE_PENDING, &item->flags))
704 setup_deferral(dreq, item, 1);
705 if (!test_bit(CACHE_PENDING, &item->flags))
709 cache_revisit_request(item);
715 static void cache_revisit_request(struct cache_head *item)
720 int hash = DFR_HASH(item);
726 if (dreq->item == item) {
775 * New readers are added to the head. If, on read, an item is found with
789 struct cache_head *item;
805 detail->cache_request(detail, crq->item, &bp, &len);
852 if (rp->offset == 0 && !test_bit(CACHE_PENDING, &rq->item->flags)) {
878 !test_bit(CACHE_PENDING, &rq->item->flags)) {
881 cache_put(rq->item, cd);
1098 if (cr->item != ch)
1111 cache_put(cr->item, detail);
1234 crq->item = cache_get(h);
1340 * We call ->cache_show passing NULL for the item to
1341 * get a header, then pass each real item in the cache