On Sun, 10 Dec 2000, Mohammad A. Haque wrote:
> Could someome who knows what they are doing check over the following
> patch please?
I wouldn't say that I do, but no one else seems to be answering this.
list_add_tail does head->prev and making the call with a NULL 'head' looks
bad to me. I would prefer:
diff -ur -X exclude linux-2.4.0-test12-pre8-orig/fs/smbfs/sock.c linux-2.4.0-test12-pre8-smbfs/fs/smbfs/sock.c
--- linux-2.4.0-test12-pre8-orig/fs/smbfs/sock.c Sun Dec 10 21:01:16 2000
+++ linux-2.4.0-test12-pre8-smbfs/fs/smbfs/sock.c Sun Dec 10 23:07:15 2000
@@ -163,7 +163,7 @@
found_data(sk);
return;
}
- job->cb.next = NULL;
+ INIT_LIST_HEAD(&job->cb.list);
job->cb.sync = 0;
job->cb.routine = smb_data_callback;
job->cb.data = job;
or just leaving the list as it is. It will be initialized anyway by
schedule_task (queue_task), but using the init macro seems like a nice
thing to do.
/Urban
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/
This archive was generated by hypermail 2b29 : Fri Dec 15 2000 - 21:00:20 EST