mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/herbert/cryptodev-2.6.git
synced 2026-04-18 03:23:53 -04:00
powerpc: Use of_property_read_bool() for boolean properties
It is preferred to use typed property access functions (i.e. of_property_read_<type> functions) rather than low-level of_get_property/of_find_property functions for reading properties. Convert reading boolean properties to of_property_read_bool(). Signed-off-by: Rob Herring <robh@kernel.org> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> Link: https://msgid.link/20230310144659.1541127-1-robh@kernel.org
This commit is contained in:
committed by
Michael Ellerman
parent
857d423c74
commit
4d57e3515e
@@ -1260,11 +1260,11 @@ struct mpic * __init mpic_alloc(struct device_node *node,
|
||||
}
|
||||
|
||||
/* Read extra device-tree properties into the flags variable */
|
||||
if (of_get_property(node, "big-endian", NULL))
|
||||
if (of_property_read_bool(node, "big-endian"))
|
||||
flags |= MPIC_BIG_ENDIAN;
|
||||
if (of_get_property(node, "pic-no-reset", NULL))
|
||||
if (of_property_read_bool(node, "pic-no-reset"))
|
||||
flags |= MPIC_NO_RESET;
|
||||
if (of_get_property(node, "single-cpu-affinity", NULL))
|
||||
if (of_property_read_bool(node, "single-cpu-affinity"))
|
||||
flags |= MPIC_SINGLE_DEST_CPU;
|
||||
if (of_device_is_compatible(node, "fsl,mpic")) {
|
||||
flags |= MPIC_FSL | MPIC_LARGE_VECTORS;
|
||||
|
||||
Reference in New Issue
Block a user