aboutsummaryrefslogtreecommitdiffstats
path: root/package/utils/nvram
Commit message (Collapse)AuthorAgeFilesLines
* packages: fix nvram makefileZoltan HERPAI2016-07-081-0/+1
| | | | Signed-off-by: Zoltan HERPAI <wigyori@uid0.hu>
* nvram: install init.d quirks script on brcm47xx onlyRafał Miłecki2016-07-071-3/+5
| | | | | | It contains some quirks for old MIPS devices. Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
* package: mark nvram and otrx nonshared as they're target specificJo-Philipp Wich2016-06-211-0/+1
| | | | Signed-off-by: Jo-Philipp Wich <jo@mein.io>
* nvram: get rid of NVRAM_SPACERafał Miłecki2015-07-082-3/+2
| | | | | | | | Now we support NVRAM whatever its size is. Signed-off-by: Rafał Miłecki <zajec5@gmail.com> git-svn-id: svn://svn.openwrt.org/openwrt/trunk@46262 3c298f89-4303-0410-b956-a3cf2f4a3e73
* nvram: fix displayed info about NVRAM sizeRafał Miłecki2015-07-081-2/+2
| | | | | | | | Use actual partition size and content offset to calculate it. Signed-off-by: Rafał Miłecki <zajec5@gmail.com> git-svn-id: svn://svn.openwrt.org/openwrt/trunk@46260 3c298f89-4303-0410-b956-a3cf2f4a3e73
* Revert "Revert "nvram: increase NVRAM size to 64 KiB""Rafał Miłecki2015-07-071-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit r45579. With the latest change r46251 ("nvram: fix "Segmentation fault" caused by setting memory out of buffer") nvram utility shouldn't crash anymore. It was tested on 3 brcm47xx devices: 1) Unknown with 0x10000 NVRAM size (0x8000 offset) 2) Linksys E1000 V2.1 with 0x10000 (0x8000 offset) 3) Linksys WRT300N V1 with 0x10000 (0x8000 offset) And 3 bcm53xx devices: 1) Buffalo WZR-600DHP2 with 0x160000 NVRAM size 2) Buffalo WZR-1750DHP with 0x10000 NVRAM size 3) Netgear R6250 V1 with 0x180000 NVRAM size (all using 0 offset) This is an important change as it allows reading whole NVRAM. This may critical when reading some basic configuration (e.g. switch ports). Signed-off-by: Rafał Miłecki <zajec5@gmail.com> git-svn-id: svn://svn.openwrt.org/openwrt/trunk@46253 3c298f89-4303-0410-b956-a3cf2f4a3e73
* nvram: fix "Segmentation fault" caused by setting memory out of bufferRafał Miłecki2015-07-071-2/+2
| | | | | | | | | | | | | Some MTD partitions with NVRAM have content starting in the middle. In such case offset is set and nvram_header returns pointer to the middle. It means we have to respect offset when calculating remaining space. By the way use real MTD partition size (nvram_part_size variable) as we may want to bump NVRAM_SPACE in the (very near) future. Signed-off-by: Rafał Miłecki <zajec5@gmail.com> git-svn-id: svn://svn.openwrt.org/openwrt/trunk@46251 3c298f89-4303-0410-b956-a3cf2f4a3e73
* Revert "nvram: increase NVRAM size to 64 KiB"Rafał Miłecki2015-04-241-1/+1
| | | | | | | | | | | | | This reverts commit ff84c27a281bc19df19bc62ee8688cca5586f6e3. This tool has really broken size handling (many values hardcoded), it crashes right now in case of NVRAM not filling whole MTD partition. Conflicts: package/utils/nvram/src/nvram.h Signed-off-by: Rafał Miłecki <zajec5@gmail.com> git-svn-id: svn://svn.openwrt.org/openwrt/trunk@45579 3c298f89-4303-0410-b956-a3cf2f4a3e73
* nvram: fix regression in finding NVRAM beginningRafał Miłecki2015-04-242-1/+7
| | | | | | | | | The loop was giving up too early as it never expected NVRAM smaller than 0x10000. Signed-off-by: Rafał Miłecki <zajec5@gmail.com> git-svn-id: svn://svn.openwrt.org/openwrt/trunk@45578 3c298f89-4303-0410-b956-a3cf2f4a3e73
* nvram: increase NVRAM size to 64 KiBRafał Miłecki2015-04-221-1/+1
| | | | | | | | | | | | | For years Broadcom devices use 64 KiB NVRAM partition size and some of them indeed have it filled in more than 50%. This change allows handling whole NVRAM e.g. on Netgear WNDR4500 and Netgear R8000. The same fix was applied to kernel in upstream commit 6ab7c29. Reported-by: Hante Meuleman <meuleman@broadcom.com> Signed-off-by: Rafał Miłecki <zajec5@gmail.com> git-svn-id: svn://svn.openwrt.org/openwrt/trunk@45566 3c298f89-4303-0410-b956-a3cf2f4a3e73
* nvram: refuse to open NVRAM for writing if it's too big to be handledRafał Miłecki2015-04-221-2/+2
| | | | | | | | Otherwise writing anything will result in loosing data. Signed-off-by: Rafał Miłecki <zajec5@gmail.com> git-svn-id: svn://svn.openwrt.org/openwrt/trunk@45565 3c298f89-4303-0410-b956-a3cf2f4a3e73
* nvram: drop check for WGT634U using /proc/diag/modelRafał Miłecki2015-04-221-11/+1
| | | | | | | | | We don't have broadcom-diag for months or years now and the correct solution is to simply don't have "nvram" partition on WGT634U anyway. Signed-off-by: Rafał Miłecki <zajec5@gmail.com> git-svn-id: svn://svn.openwrt.org/openwrt/trunk@45564 3c298f89-4303-0410-b956-a3cf2f4a3e73
* nvram: use correct variable name for MTD partition sizeRafał Miłecki2015-04-221-13/+14
| | | | | | | | | | Sytax of /proc/mtd is following: dev: size erasesize name which means that sscanf "mtd%d: %08x" reads size, not erasesize. Signed-off-by: Rafał Miłecki <zajec5@gmail.com> git-svn-id: svn://svn.openwrt.org/openwrt/trunk@45563 3c298f89-4303-0410-b956-a3cf2f4a3e73
* nvram: drop support for ancient /dev/mtdblock/%dRafał Miłecki2015-04-221-13/+1
| | | | | | | | Path /dev/mtdblock%d is used for years now. Signed-off-by: Rafał Miłecki <zajec5@gmail.com> git-svn-id: svn://svn.openwrt.org/openwrt/trunk@45562 3c298f89-4303-0410-b956-a3cf2f4a3e73
* nvram: remove libnvram.so, it is unused and incompatible to the broadcom API ↵Felix Fietkau2014-12-132-38/+4
| | | | | | | | anyway Signed-off-by: Felix Fietkau <nbd@openwrt.org> git-svn-id: svn://svn.openwrt.org/openwrt/trunk@43698 3c298f89-4303-0410-b956-a3cf2f4a3e73
* license info - revert r43155John Crispin2014-11-031-3/+0
| | | | | | | | turns out that r43155 adds duplicate info. Signed-off-by: John Crispin <blogic@openwrt.org> git-svn-id: svn://svn.openwrt.org/openwrt/trunk@43167 3c298f89-4303-0410-b956-a3cf2f4a3e73
* Add more license tags with SPDX identifiersJohn Crispin2014-11-031-0/+3
| | | | | | | | | | | | | | | | | | Note, that licensing stuff is a nightmare: many packages does not clearly state their licenses, and often multiple source files are simply copied together - each with different licensing information in the file headers. I tried hard to ensure, that the license information extracted into the OpenWRT's makefiles fit the "spirit" of the packages, e.g. such small packages which come without a dedicated source archive "inherites" the OpenWRT's own license in my opinion. However, I can not garantee that I always picked the correct information and/or did not miss license information. Signed-off-by: Michael Heimpold <mhei@heimpold.de> git-svn-id: svn://svn.openwrt.org/openwrt/trunk@43155 3c298f89-4303-0410-b956-a3cf2f4a3e73
* package: nvram: enable on bcm53xx targetHauke Mehrtens2014-09-131-1/+1
| | | | | | | | | | It uses mtd, so doesn't require any special adjustments for new target. It has been succesfully tested (reading, writing and commiting). Signed-off-by: Rafał Miłecki <zajec5@gmail.com> git-svn-id: svn://svn.openwrt.org/openwrt/trunk@42521 3c298f89-4303-0410-b956-a3cf2f4a3e73
* packages: clean up the package folderJohn Crispin2013-06-218-0/+1215
Signed-off-by: John Crispin <blogic@openwrt.org> git-svn-id: svn://svn.openwrt.org/openwrt/trunk@37007 3c298f89-4303-0410-b956-a3cf2f4a3e73