Blame view

common/cmd_ext2.c 1.36 KB
bcd0be5cf   stroese   ext2fs support added
1
  /*
a1596438a   Uma Shankar   ext4fs ls load su...
2
3
4
5
   * (C) Copyright 2011 - 2012 Samsung Electronics
   * EXT4 filesystem implementation in Uboot by
   * Uma Shankar <uma.shankar@samsung.com>
   * Manjunatha C Achar <a.manjunatha@samsung.com>
bcd0be5cf   stroese   ext2fs support added
6
7
8
9
10
11
12
13
14
15
   * (C) Copyright 2004
   * esd gmbh <www.esd-electronics.com>
   * Reinhard Arlt <reinhard.arlt@esd-electronics.com>
   *
   * made from cmd_reiserfs by
   *
   * (C) Copyright 2003 - 2004
   * Sysgo Real-Time Solutions, AG <www.elinos.com>
   * Pavel Bartusek <pba@sysgo.com>
   *
1a4596601   Wolfgang Denk   Add GPL-2.0+ SPDX...
16
   * SPDX-License-Identifier:	GPL-2.0+
bcd0be5cf   stroese   ext2fs support added
17
18
19
20
21
   */
  
  /*
   * Ext2fs support
   */
045fa1e11   Stephen Warren   fs: add filesyste...
22
  #include <fs.h>
bcd0be5cf   stroese   ext2fs support added
23

54841ab50   Wolfgang Denk   Make sure that ar...
24
  int do_ext2ls (cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[])
bcd0be5cf   stroese   ext2fs support added
25
  {
045fa1e11   Stephen Warren   fs: add filesyste...
26
  	return do_ls(cmdtp, flag, argc, argv, FS_TYPE_EXT);
bcd0be5cf   stroese   ext2fs support added
27
  }
bcd0be5cf   stroese   ext2fs support added
28
29
30
  /******************************************************************************
   * Ext2fs boot command intepreter. Derived from diskboot
   */
54841ab50   Wolfgang Denk   Make sure that ar...
31
  int do_ext2load (cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[])
bcd0be5cf   stroese   ext2fs support added
32
  {
b770e88a6   Wolfgang Denk   Fix number base h...
33
  	return do_load(cmdtp, flag, argc, argv, FS_TYPE_EXT);
bcd0be5cf   stroese   ext2fs support added
34
35
36
  }
  
  U_BOOT_CMD(
a1596438a   Uma Shankar   ext4fs ls load su...
37
38
39
40
41
42
43
44
  	ext2ls,	4,	1,	do_ext2ls,
  	"list files in a directory (default /)",
  	"<interface> <dev[:part]> [directory]
  "
  	"    - list files from 'dev' on 'interface' in a 'directory'"
  );
  
  U_BOOT_CMD(
bcd0be5cf   stroese   ext2fs support added
45
  	ext2load,	6,	0,	do_ext2load,
2fb2604d5   Peter Tyser   Command usage cle...
46
  	"load binary file from a Ext2 filesystem",
bcd0be5cf   stroese   ext2fs support added
47
48
49
50
  	"<interface> <dev[:part]> [addr] [filename] [bytes]
  "
  	"    - load binary file 'filename' from 'dev' on 'interface'
  "
b770e88a6   Wolfgang Denk   Fix number base h...
51
  	"      to address 'addr' from ext2 filesystem."
bcd0be5cf   stroese   ext2fs support added
52
  );