Linux NFS development
 help / color / mirror / Atom feed
* question about fs/nfs/direct.c
@ 2012-07-08  9:15 Julia Lawall
  2012-07-08 14:34 ` Myklebust, Trond
  0 siblings, 1 reply; 3+ messages in thread
From: Julia Lawall @ 2012-07-08  9:15 UTC (permalink / raw)
  To: Trond.Myklebust, linux-nfs

The following code, in the function nfs_direct_write_reschedule, looks 
strange to me:

         list_for_each_entry_safe(req, tmp, &reqs, wb_list) {
                 if (!nfs_pageio_add_request(&desc, req)) {
                         nfs_list_add_request(req, &failed);
                         spin_lock(cinfo.lock);
                         dreq->flags = 0;
                         dreq->error = -EIO;
                         spin_unlock(cinfo.lock);
                 }
                 nfs_release_request(req);
         }
         nfs_pageio_complete(&desc);

         while (!list_empty(&failed))
                 nfs_unlock_and_release_request(req);

After the list_for_each_entry_safe, req is an address at some offset from 
the list head.  So it does not seem like an appropriate argument to 
nfs_unlock_and_release_request.

julia

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2012-07-08 14:42 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-07-08  9:15 question about fs/nfs/direct.c Julia Lawall
2012-07-08 14:34 ` Myklebust, Trond
2012-07-08 14:42   ` Julia Lawall

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox