[PATCH 0/2 (try 2)] mtd: ubi: implement the new command 'ubirename'

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Here a new set of patches implementing the command 'ubirename'.

They are based on a patch serie from Sascha that restructures a bit
the barebox UBI APIs. In particular it is now easier to find the ubi
volume ids from the command code. Moreover the command code uses now
api functions to do the rename.

This new set also fixes some minor cosmetic details noted by Sascha and
a real problem found in the function 'get_vol_id()': it was missing
a call to 'ubi_close_volume(desc)' hence leaving ubi volumes busy.
A simple test that showed the problem was:

bb> ubimkvol /dev/nand0.ubi_volumes.ubi vol_A 10MiB
bb> ubirename /dev/nand0.ubi_volumes.ubi vol_A vol_B
bb> ubirmvol /dev/nand0.ubi_volumes.ubi vol_B

The last command, ubirmvol, failed because 'vol_B' appeared to be still
busy after the rename (vol->readers==1).
	
Giorgio Dal Molin (2):
  mtd: ubi: add API call to rename volumes.
  mtd: ubi: commands: added the new command 'ubirename'.

 commands/ubi.c            |  72 +++++++++++++++++++++
 drivers/mtd/ubi/barebox.c | 156 ++++++++++++++++++++++++++++++++++++++++++++++
 drivers/mtd/ubi/vmt.c     |   3 +
 include/linux/mtd/ubi.h   |   1 +
 4 files changed, 232 insertions(+)

-- 
2.10.0


_______________________________________________
barebox mailing list
barebox@xxxxxxxxxxxxxxxxxxx
http://lists.infradead.org/mailman/listinfo/barebox



[Index of Archives]     [Linux Embedded]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux