Re: [PATCH]: Atmel Serial Console interrupt handler splitup

From: Haavard Skinnemoen
Date: Tue Dec 18 2007 - 05:30:08 EST


On Tue, 18 Dec 2007 12:08:05 +0200
"Andrew Victor" <avictor.za@xxxxxxxxx> wrote:

> > #define at_readl(port, off) __raw_readl((port)->membase + (off))
> > #define at_writel(v, port, off) __raw_writel(v, (port)->membase + (off))
> >
> > #define UART_PUT_CR(port, v) at_writel(v, port, ATMEL_US_CR)
> > #define UART_PUT_MR(port, v) at_writel(v, port, ATMEL_US_MR)
>
> I'd like to point out this relatively recent change to CodingStyle.
> http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=dff4982f5cd4e30e2a140a3bca95d8814115bf5b
>
> So I don't see a reason for complicating the code by adding additional
> macro's just to fit it in 80 column's.

Hmm...yes, I think that change to the CodingStyle makes sense. But I
guess the question is whether the old code "significantly increases
readability" and whether the new code "hides information".

I don't think so, but I don't feel all that strongly about it. I'd
actually prefer if we used at_writel() and at_readl() throughout the
code and killed those UART_PUT/UART_GET macros.

Haavard
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/