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
| ||
|
Date: Fri, 13 Oct 2017 00:35:57 -0700 From: Stephen Boyd <stephen.boyd@...aro.org> To: Rob Herring <robh+dt@...nel.org>, Frank Rowand <frowand.list@...il.com> Cc: linux-kernel@...r.kernel.org, devicetree@...r.kernel.org Subject: [PATCH 1/2] of/resolver: Simplify to be32_add_cpu() This is the same as be32_add_cpu(), so simplify the code and remove the now unused local variable. Signed-off-by: Stephen Boyd <stephen.boyd@...aro.org> --- drivers/of/resolver.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/drivers/of/resolver.c b/drivers/of/resolver.c index 99309cb7d372..2d58253bf2f7 100644 --- a/drivers/of/resolver.c +++ b/drivers/of/resolver.c @@ -165,7 +165,6 @@ static int adjust_local_phandle_references(struct device_node *local_fixups, struct property *prop_fix, *prop; int err, i, count; unsigned int off; - phandle phandle; if (!local_fixups) return 0; @@ -195,9 +194,7 @@ static int adjust_local_phandle_references(struct device_node *local_fixups, if ((off + 4) > prop->length) return -EINVAL; - phandle = be32_to_cpu(*(__be32 *)(prop->value + off)); - phandle += phandle_delta; - *(__be32 *)(prop->value + off) = cpu_to_be32(phandle); + be32_add_cpu(prop->value + off, phandle_delta); } } -- 2.14.GIT
Powered by blists - more mailing lists