mirror of
https://github.com/AsahiLinux/u-boot
synced 2024-12-12 22:33:18 +00:00
15dd941202
The logic in msm_generate_mac_addr() was originally taken from the LK bootloader where the serial number is a string and must be parsed first. However, in U-Boot msm_board_serial() returns an u32 and msm_generate_mac_addr() has quite complicated code that will first print it as a hex string and then immediately parse it again. What this function actually does at the end is to put the serial number encoded as big endian (the order used for the hex string) into the u8 *mac. Use put_unaligned_be32() to do that with bit shifts instead of going through the string format. This should be slightly more efficient and cleaner but does not result in any functional difference. Cc: Ramon Fried <rfried.dev@gmail.com> Signed-off-by: Stephan Gerhold <stephan@gerhold.net> Reviewed-by: Ramon Fried <rfried.dev@gmail.com> |
||
---|---|---|
.. | ||
include/mach | ||
clock-apq8016.c | ||
clock-apq8096.c | ||
clock-snapdragon.c | ||
clock-snapdragon.h | ||
dram.c | ||
Kconfig | ||
Makefile | ||
misc.c | ||
pinctrl-apq8016.c | ||
pinctrl-apq8096.c | ||
pinctrl-snapdragon.c | ||
pinctrl-snapdragon.h | ||
sysmap-apq8016.c | ||
sysmap-apq8096.c |