On Mon, 2011-12-12 at 21:33 +0100, Rafał Miłecki wrote: Hi Rafał. > diff --git a/drivers/bcma/sprom.c b/drivers/bcma/sprom.c [] > @@ -136,6 +139,42 @@ static void bcma_sprom_extract_r8(struct bcma_bus *bus, const u16 *sprom) > > bus->sprom.board_rev = sprom[SPOFF(SSB_SPROM8_BOARDREV)]; > > + bus->sprom.txpid2g[0] = (sprom[SPOFF(SSB_SPROM4_TXPID2G01)] & > + SSB_SPROM4_TXPID2G0) >> SSB_SPROM4_TXPID2G0_SHIFT; This is a bit "wall of uppercase text" for my taste. Perhaps a macro like: #define GET_SPROM(val, mask, shift) \ (sprom[SPOFF(SSB_SPROM4_TXPID##val)] & SSB_SPROM4_TXPID##mask) >>\ SSB_SPROM4_TXPID##shift##_SHIFT; So these become: > + bus->sprom.txpid2g[1] = (sprom[SPOFF(SSB_SPROM4_TXPID2G01)] & > + SSB_SPROM4_TXPID2G1) >> SSB_SPROM4_TXPID2G1_SHIFT; bus->sprom.txpid2g[1] = GET_SPROM(2G01, 2G1, 2G1); > + bus->sprom.txpid2g[2] = (sprom[SPOFF(SSB_SPROM4_TXPID2G23)] & > + SSB_SPROM4_TXPID2G2) >> SSB_SPROM4_TXPID2G2_SHIFT; bus->sprom.tpid2g[2] = GET_SPROM(2G23, 2G2, 2G2); > + bus->sprom.txpid2g[3] = (sprom[SPOFF(SSB_SPROM4_TXPID2G23)] & > + SSB_SPROM4_TXPID2G3) >> SSB_SPROM4_TXPID2G3_SHIFT; etc. -- To unsubscribe from this list: send the line "unsubscribe linux-wireless" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html