question about fs/nfs/direct.c

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



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
--
To unsubscribe from this list: send the line "unsubscribe linux-nfs" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Filesystem Development]     [Linux USB Development]     [Linux Media Development]     [Video for Linux]     [Linux NILFS]     [Linux Audio Users]     [Yosemite Info]     [Linux SCSI]

  Powered by Linux