Search Linux Wireless

Re: [PATCH 6/6] staging: wilc1000: fix line over 80 chars in wilc_spi_clear_int_ext()

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

 



On Fri, 16 Feb 2018 20:16:02 +0200
Claudiu Beznea <Claudiu.Beznea@xxxxxxxxxxxxx> wrote:

> Or you could use:
> 	unsigned long expected_irqs, unexpected_irqs;
> 
> 	expected_irqs = val & GENMASK(g_spi.int - 1, 0);
> 	unexpected_irq = val & GENMASK(MAX_NUM_INT - 1, g_spi.int);
> 
> 	for (i = 0; i < g_spi.nint && expected_irqs; i++) {
> 		if (expected_irqs & BIT(i)) {
> 			ret = wilc_spi_write_reg(wilc, 0x10c8 + i * 4, 1);
> 			if (ret) {
> 				dev_err(...);
> 				goto _fail_;
> 			}
> 		}
> 	}
> 
> 	for (i = g_spi.nint; i < MAX_NUM_INT && unexpected_irq; i++) {
> 		if (unexpected_irqs & BIT(i))
> 			dev_err(...);
> 

Thanks for suggestion.
I will take this input and make use of GENMASK macro to modify the
function. In a separate patch will submit these changes. As there are
other functions,where same macro can be used so will include them
together in separate patch.



[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Wireless Personal Area Network]     [Linux Bluetooth]     [Wireless Regulations]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite Hiking]     [MIPS Linux]     [ARM Linux]     [Linux RAID]

  Powered by Linux