lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:	Mon, 14 Dec 2015 17:57:56 +0000
From:	Mark Brown <broonie@...nel.org>
To:	Xiubo Li <lixiubo@...s.chinamobile.com>
Cc:	linux-kernel@...r.kernel.org
Subject: Re: [PATCH] regmap: flat: introduce register striding to save some
 memories

On Mon, Dec 14, 2015 at 03:14:34PM +0800, Xiubo Li wrote:

>  static int regcache_flat_write(struct regmap *map, unsigned int reg,
>  			       unsigned int value)
>  {
> +	unsigned int index = reg / map->reg_stride;

So, this does save some memory.  On the other hand one of the big goals
for the flat cache is to be as fast as possible to match the performance
of MMIO and divisions aren't the cheapest operations.  If this was the
rbtree cache then it'd not be an issue but in the flat cache speed is
definitely the top priority, at least by default.

I'm guessing for your particular register maps the performance isn't too
big an issue...  do you have any numbers for how much space you're
saving overall?  Is it worth finding a way to make this possible to
enable on maps that benefit?

Download attachment "signature.asc" of type "application/pgp-signature" (474 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ