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

Ajay Singh ajay.kathat at microchip.com
Mon Feb 19 07:49:36 UTC 2018


On Fri, 16 Feb 2018 20:16:02 +0200
Claudiu Beznea <Claudiu.Beznea at microchip.com> 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.


More information about the devel mailing list