On Thu, 11 Dec 2003, Duncan Sands wrote:

> What about
> 
>       dev->toggle[out] |= (!!bit) << ep;
> 
> ?

That should work too.

> PS: Since the previous version worked, and this one doesn't,
> what changed?  It must be the argument types, right?

Of course, if the original macro worked then so should all of these
proposals, including the official definition.  Signedness doesn't matter
for left shifts.

It would be nice to know exactly which usage of usb_settoggle was causing
the problem.  The one in core/devio.c seems most likely.  Most of the 
others are in the HC drivers; if they were messed up probably nothing 
would work at all.

An interesting test would be to leave the official definition in usb.h but
rewrite that one occurrence by hand, using the macro expansion.  If that
fixes the problem, more investigation could proceed from there.

Alan Stern



-------------------------------------------------------
This SF.net email is sponsored by: IBM Linux Tutorials.
Become an expert in LINUX or just sharpen your skills.  Sign up for IBM's
Free Linux Tutorials.  Learn everything from the bash shell to sys admin.
Click now! http://ads.osdn.com/?ad_id=1278&alloc_id=3371&op=click
_______________________________________________
[EMAIL PROTECTED]
To unsubscribe, use the last form field at:
https://lists.sourceforge.net/lists/listinfo/linux-usb-devel

Reply via email to