Re: WARNING in wdm_write/usb_submit_urb

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

 



Oliver Neukum <oneukum@xxxxxxxx> writes:

> +	wait_event(desc->wait,
> +			/*
> +			 * needs both flags. We cannot do with one
> +			 * because resetting it would cause a race
> +			 * with write() yet we need to signal
> +			 * a disconnect
> +			 */
> +			!test_bit(WDM_IN_USE, &desc->flags) &&
> +			test_bit(WDM_DISCONNECTING, &desc->flags));

I'm confused now...  Won't this condition always be false?
Should be

  wait_event(desc->wait,
             !test_bit(WDM_IN_USE, &desc->flags) ||
             test_bit(WDM_DISCONNECTING, &desc->flags));


instead, or?



Bjørn




[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux