[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <53FE09E2.5080708@wwwdotorg.org>
Date: Wed, 27 Aug 2014 10:40:02 -0600
From: Stephen Warren <swarren@...dotorg.org>
To: Geert Uytterhoeven <geert+renesas@...der.be>,
Mark Brown <broonie@...nel.org>
CC: Javier Martinez Canillas <javier.martinez@...labora.co.uk>,
Stephen Warren <swarren@...dia.com>,
Xiubo Li <Li.Xiubo@...escale.com>, linux-kernel@...r.kernel.org
Subject: Re: [PATCH RFC] regmap: Split regmap_get_endian() in two functions
On 08/27/2014 08:36 AM, Geert Uytterhoeven wrote:
> Split regmap_get_endian() in two functions, regmap_get_reg_endian() and
> regmap_get_val_endian().
>
> This allows to:
> - Get rid of the three switch()es on "type", incl. error handling in
> three "default" cases,
> - Get rid of the regmap_endian_type enum,
> - Get rid of the non-NULL check of "config" (regmap_init() already
> checks for that),
> - Get rid of the "endian" output parameters, and just return the
> regmap_endian enum value, as the functions can no longer fail.
>
> This saves 21 lines of code (despite the still-present
> one-comment-per-line over-documentation), and 30 bytes of code on ARM
> V7.
For the mailing list record only (since it's been applied),
Reviewed-by: Stephen Warren <swarren@...dia.com>
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists