summaryrefslogtreecommitdiffstats
path: root/board/mpl/vcma9/cmd_vcma9.c
Commit message (Collapse)AuthorAgeFilesLines
* Add GPL-2.0+ SPDX-License-Identifier to source filesWolfgang Denk2013-07-241-18/+1
| | | | | | Signed-off-by: Wolfgang Denk <wd@denx.de> [trini: Fixup common/cmd_io.c] Signed-off-by: Tom Rini <trini@ti.com>
* VCMA9: various cleanups/code style fixesDavid Müller (ELSOFT AG)2011-07-041-53/+3
| | | | Signed-off-by: David Müller <d.mueller@elsoft.ch>
* Make sure that argv[] argument pointers are not modified.Wolfgang Denk2010-07-041-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The hush shell dynamically allocates (and re-allocates) memory for the argument strings in the "char *argv[]" argument vector passed to commands. Any code that modifies these pointers will cause serious corruption of the malloc data structures and crash U-Boot, so make sure the compiler can check that no such modifications are being done by changing the code into "char * const argv[]". This modification is the result of debugging a strange crash caused after adding a new command, which used the following argument processing code which has been working perfectly fine in all Unix systems since version 6 - but not so in U-Boot: int main (int argc, char **argv) { while (--argc > 0 && **++argv == '-') { /* ====> */ while (*++*argv) { switch (**argv) { case 'd': debug++; break; ... default: usage (); } } } ... } The line marked "====>" will corrupt the malloc data structures and usually cause U-Boot to crash when the next command gets executed by the shell. With the modification, the compiler will prevent this with an error: increment of read-only location '*argv' N.B.: The code above can be trivially rewritten like this: while (--argc > 0 && **++argv == '-') { char *arg = *argv; while (*++arg) { switch (*arg) { ... Signed-off-by: Wolfgang Denk <wd@denx.de> Acked-by: Mike Frysinger <vapier@gentoo.org>
* Convert CS8900 Ethernet driver to CONFIG_NET_MULTI APIBen Warren2009-08-251-10/+18
| | | | | | | | | | | | | | | All in-tree boards that use this controller have CONFIG_NET_MULTI added Also: - changed CONFIG_DRIVER_CS8900 to CONFIG_CS8900 - changed CS8900_BASE to CONFIG_CS8900_BASE - changed CS8900_BUS?? to CONFIG_CS8900_BUS?? - cleaned up line lengths - modified VCMA9 command function that accesses the device - removed MAC address initialization from lib_arm/board.c Signed-off-by: Ben Warren <biggerbadderben@gmail.com> Tested-by: Wolfgang Denk <wd@denx.de> Acked-by: Wolfgang Denk <wd@denx.de>
* General help message cleanupWolfgang Denk2009-06-121-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Many of the help messages were not really helpful; for example, many commands that take no arguments would not print a correct synopsis line, but "No additional help available." which is not exactly wrong, but not helpful either. Commit ``Make "usage" messages more helpful.'' changed this partially. But it also became clear that lots of "Usage" and "Help" messages (fields "usage" and "help" in struct cmd_tbl_s respective) were actually redundant. This patch cleans this up - for example: Before: => help dtt dtt - Digital Thermometer and Thermostat Usage: dtt - Read temperature from digital thermometer and thermostat. After: => help dtt dtt - Read temperature from Digital Thermometer and Thermostat Usage: dtt Signed-off-by: Wolfgang Denk <wd@denx.de>
* VCMA9: fix compile errorsWolfgang Denk2009-03-291-2/+3
| | | | | | | | Fix these: cmd_vcma9.c:82: warning: implicit declaration of function 'eth_getenv_enetaddr' cmd_vcma9.c:89: error: 'enetaddr' undeclared (first use in this function) Signed-off-by: Wolfgang Denk <wd@denx.de>
* boards: get mac address from environmentMike Frysinger2009-03-201-7/+4
| | | | | | | | | | | | | | | | | | | | | | | | The boards that get converted here to use the environment for the mac address rather than global data: debris mgcoge mgsuvd muas3001 netstal pn62 sixnet vcma9 xilinx (the ones that use xilinx_enet) Signed-off-by: Mike Frysinger <vapier@gentoo.org> CC: Ben Warren <biggerbadderben@gmail.com> CC: Sangmoon Kim <dogoil@etinsys.com> CC: Heiko Schocher <hs@denx.de> CC: David Mueller <d.mueller@elsoft.ch> CC: Niklaus Giger <niklaus.giger@netstal.com> CC: Wolfgang Grandegger <wg@denx.de> CC: Dave Ellis <DGE@sixnetio.com> CC: Ricardo Ribalda <ricardo.ribalda@uam.es>
* Command usage cleanupPeter Tyser2009-01-281-1/+1
| | | | | | | | Remove command name from all command "usage" fields and update common/command.c to display "name - usage" instead of just "usage". Also remove newlines from command usage fields. Signed-off-by: Peter Tyser <ptyser@xes-inc.com>
* Big white-space cleanup.Wolfgang Denk2008-05-211-2/+2
| | | | | | | | | | | This commit gets rid of a huge amount of silly white-space issues. Especially, all sequences of SPACEs followed by TAB characters get removed (unless they appear in print statements). Also remove all embedded "vim:" and "vi:" statements which hide indentation problems. Signed-off-by: Wolfgang Denk <wd@denx.de>
* drivers/net : move net drivers to drivers/netJean-Christophe PLAGNIOL-VILLARD2007-11-251-1/+1
| | | | Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
* Fix cases where DECLARE_GLOBAL_DATA_PTR was not declared as globalWolfgang Denk2007-09-151-2/+2
| | | | Signed-off-by: Wolfgang Denk <wd@denx.de>
* * Patches by David Müller, 14 Nov 2003:wdenk2003-12-071-5/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - board/mpl/common/common_util.c * implement support for BZIP2 compressed images * various cleanups (printf -> puts, ...) - board/mpl/common/flash.c * report correct errors to upper layers * check the erase fail and VPP low bits in status reg - board/mpl/vcma9/cmd_vcma9.c - board/mpl/vcma9/flash.c * various cleanups (printf -> puts, ...) - common/cmd_usb.c * fix typo in comment - cpu/arm920t/usb_ohci.c * support for S3C2410 is missing in #if line - drivers/cs8900.c * reinit some registers in case of error (cable missing, ...) - fs/fat/fat.c * support for USB/MMC devices is missing in #if line - include/configs/MIP405.h - include/configs/PIP405.h * enable BZIP2 support * enlarge malloc space to 1MiB because of BZIP2 support - include/configs/VCMA9.h * enable BZIP2 support * enlarge malloc space to 1MiB because of BZIP2 support * enable USB support - lib_arm/armlinux.c * change calling convention of ARM Linux kernel as described on http://www.arm.linux.org.uk/developer/booting.php * Patch by Thomas Lange, 14 Nov 2003: Split dbau1x00 into dbau1000, dbau1100 and dbau1500 configs to support all these AMD boards. * Patch by Thomas Lange, 14 Nov 2003: Workaround for mips au1x00 physical memory accesses (the au1x00 uses a 36 bit bus internally and cannot access physical memory directly. Use the uncached SDRAM address instead of the physical one.)
* * Patches by Xianghua Xiao, 15 Oct 2003:wdenk2003-10-151-1/+0
| | | | | | | | - Added Motorola CPU 8540/8560 support (cpu/85xx) - Added Motorola MPC8540ADS board support (board/mpc8540ads) - Added Motorola MPC8560ADS board support (board/mpc8560ads) * Minor code cleanup
* * Patch by David Müller, 13 Sep 2003:wdenk2003-09-131-4/+42
| | | | | | various changes to VCMA9 board specific files * Add I2C support for MGT5100 / MPC5200
* * Code cleanup:wdenk2003-06-271-1/+0
| | | | | | | | | - remove trailing white space, trailing empty lines, C++ comments, etc. - split cmd_boot.c (separate cmd_bdinfo.c and cmd_load.c) * Patches by Kenneth Johansson, 25 Jun 2003: - major rework of command structure (work done mostly by Michal Cendrowski and Joakim Kristiansen)
* * Avoid flicker on the TRAB's VFD by synchronizing the enable withwdenk2003-03-141-1/+1
| | | | | | | | | | | | | | | | | | | the HSYNC/VSYNC. Requires new CPLD code (Version 101 for Rev. 100 boards, version 153 for Rev. 200 boards). * Patch by Vladimir Gurevich, 12 Mar 2003: Fix relocation problem of statically initialized string pointers in common/cmd_pci.c * Patch by Kai-Uwe Blöm, 12 Mar 2003: Cleanup & bug fixes for JFFS2 code: - the memory mangement was broken. It caused havoc on malloc by writing beyond the block boundaries. - the length calculation for files was wrong, sometimes resulting in short file reads. - data copying now optionally takes fragment version numbers into account, to avoid copying from older data. See doc/README.JFFS2 for details.
* * Patches by David Müller, 31 Jan 2003:wdenk2003-03-061-0/+144
- minimal setup for CardBus bridges - add EEPROM read/write support in the CS8900 driver - add support for the builtin I2C controller in the Samsung s3c24x0 chips - add support for MPL's VCMA9 (Samsung s3c2410 based) board * Patch by Steven Scholz, 04 Feb 2003: add support for RTC DS1307 * Patch by Reinhard Meyer, 5 Feb 2003: fix PLPRCR/SCCR init sequence on 8xx to allow for changes of EBDF by software * Patch by Vladimir Gurevich, 07 Feb 2003: "API-compatibility patch" for 4xx I2C driver
OpenPOWER on IntegriCloud