projects
/
openwrt
/
.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
ramips: Speed up eeprom read/write
[openwrt/.git]
/
target
/
linux
/
ramips
/
base-files
/
etc
/
hotplug.d
/
firmware
/
10-rt2x00-eeprom
diff --git
a/target/linux/ramips/base-files/etc/hotplug.d/firmware/10-rt2x00-eeprom
b/target/linux/ramips/base-files/etc/hotplug.d/firmware/10-rt2x00-eeprom
index 13a4687251e1eb39c56fc8985ead145614176b46..96a239719113575da1e6ceafddfb0dfa4a98b8f1 100644
(file)
--- a/
target/linux/ramips/base-files/etc/hotplug.d/firmware/10-rt2x00-eeprom
+++ b/
target/linux/ramips/base-files/etc/hotplug.d/firmware/10-rt2x00-eeprom
@@
-15,7
+15,7
@@
rt2x00_eeprom_extract() {
[ -n "$mtd" ] || \
rt2x00_eeprom_die "no mtd device found for partition $part"
[ -n "$mtd" ] || \
rt2x00_eeprom_die "no mtd device found for partition $part"
- dd if=$mtd of=/lib/firmware/$FIRMWARE
bs=1 skip=$offset count=$count
2>/dev/null || \
+ dd if=$mtd of=/lib/firmware/$FIRMWARE
iflag=skip_bytes bs=$count skip=$offset count=1
2>/dev/null || \
rt2x00_eeprom_die "failed to extract from $mtd"
}
rt2x00_eeprom_die "failed to extract from $mtd"
}
@@
-39,7
+39,7
@@
rt2x00_eeprom_set_macaddr() {
rt2x00_eeprom_die "invalid wlan mac address"
macaddr_2bin $macaddr | dd of=/lib/firmware/$FIRMWARE \
rt2x00_eeprom_die "invalid wlan mac address"
macaddr_2bin $macaddr | dd of=/lib/firmware/$FIRMWARE \
- conv=notrunc
bs=1 seek=4 count=6
2>/dev/null || \
+ conv=notrunc
oflag=seek_bytes bs=6 seek=4 count=1
2>/dev/null || \
rt2x00_eeprom_die "failed to write mac address to eeprom file"
}
rt2x00_eeprom_die "failed to write mac address to eeprom file"
}