RE: [PATCH] OMAP: GPIO: Avoid generating extra IRQs

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

 



>>               l ^= bank->saved_datain;
>>               l &= bank->non_wakeup_gpios;
>> -             if (l) {
>> +
>> +             /*
>> +              * No need to generate IRQs for the rising edge for gpio IRQs
>> +              * configured with falling edge only; and vice versa.
>> +              */
>> +             gen0 = l & bank->saved_fallingdetect;
>> +             gen0 &= bank->saved_datain;
>> +
>> +             gen1 = l & bank->saved_risingdetect;
>> +             gen1 &= ~(bank->saved_datain);
>> +

> Is the gen0 &= correct or should it also clear the bits?

What do you mean, eg, what bits should be cleared?

gen0 = (bit has changed) and is falling_edge
gen0 &= (the bit has changed) is falling edge and former state was "HIGH"
(transition from HIGH to LOW has occurred)

for rising edge, needed is LOW to HIGH transition.

- Eero--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Arm (vger)]     [ARM Kernel]     [ARM MSM]     [Linux Tegra]     [Linux WPAN Networking]     [Linux Wireless Networking]     [Maemo Users]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite Trails]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux