Chris, On Mon, 2007-02-05 at 12:06 -0800, Christopher Li wrote: > On Mon, Feb 05, 2007 at 10:54:20AM -0800, Randy Dunlap wrote: > > The skbuff.[hc] difference is in *getfrag vs. getfrag. > > The mpage.[hc] difference is in *get_block vs. getblock. I remember having this problem in MadWifi, and it was hard to understand what was going on. I had to put the declarations back-to-back and look at them very carefully. > > Questions: > > 1. Is the warning valid? > > I don't think so. I think any difference between declarations other than missing argument names is an example of sloppy coding and should be avoided. > > 2. Isn't the '*' unnecessary? > > It is valid in C without '*'. Sparse already know the function > is going to degenerated into function pointers. It wrongly inherent > the signedness. You get a signed pointer. > > Can you please try this patch? I would prefer that sparse emits a specific warning about function vs function pointer mismatch. Even if it doesn't matter, it makes the code easier to read and safer to modify. -- Regards, Pavel Roskin - To unsubscribe from this list: send the line "unsubscribe linux-sparse" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html