ARM: orion5x: Revert commit 4904dbda41c8.
authorDavid S. Miller <davem@davemloft.net>
Mon, 26 Feb 2018 18:41:47 +0000 (13:41 -0500)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 30 May 2018 05:52:05 +0000 (07:52 +0200)
commit0129ee813ef7ea0c7abafcaf3ec425306282d756
treefd6512e092ce603968c66957df38ebfbf5850713
parent3ecb681ccf6b1853e7acd912cb7d13e6f97fb525
ARM: orion5x: Revert commit 4904dbda41c8.

[ Upstream commit 13a55372b64e00e564a08d785ca87bd9d454ba30 ]

It is not valid for orion5x to use mac_pton().

First of all, the orion5x buffer is not NULL terminated.  mac_pton()
has no business operating on non-NULL terminated buffers because
only the caller can know that this is valid and in what manner it
is ok to parse this NULL'less buffer.

Second of all, orion5x operates on an __iomem pointer, which cannot
be dereferenced using normal C pointer operations.  Accesses to
such areas much be performed with the proper iomem accessors.

Fixes: 4904dbda41c8 ("ARM: orion5x: use mac_pton() helper")
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Sasha Levin <alexander.levin@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
arch/arm/mach-orion5x/Kconfig
arch/arm/mach-orion5x/dns323-setup.c
arch/arm/mach-orion5x/tsx09-common.c