From mboxrd@z Thu Jan 1 00:00:00 1970 From: Lukasz Majewski Date: Fri, 17 Aug 2012 08:46:58 +0200 Subject: [U-Boot] [PATCH 2/3] cmd_partuuid: add command to retrieve a partition's UUID In-Reply-To: <502D805C.5090809@wwwdotorg.org> References: <1345158942-31512-1-git-send-email-swarren@wwwdotorg.org> <1345158942-31512-2-git-send-email-swarren@wwwdotorg.org> <502D805C.5090809@wwwdotorg.org> Message-ID: <20120817084658.3ea31f2a@amdc308.digital.local> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Hi Stephen, > On 08/16/2012 05:15 PM, Stephen Warren wrote: > > This implements the following: > > > > partuuid mmc 0:1 > > -> prints the partition's UUID. > > partuuic mmc 0:1 uuid > > -> sets environment variable "uuid" to the partition's UUID. > > > > This can be useful when writing a bootcmd which searches all known > > devices for something bootable, and then wants the kernel to use the > > same partition as the root device, e.g.: > > > > partuuid ${devtype} ${devnum}:${rootpart} uuid > > setenv bootargs root=PARTUUID=${uuid} ... > > I guess one thing I might mention here: > > I can imagine other partition-oriented commands existing, e.g. a > command to find the bootable partition on a particular storage > device. I'm not sure if we should create a single "part" command with > various sub-options for this, e.g.: > > part uuid mmc 0:1 > part get-bootable mmc 0 > I'm now working at restoring the GPT (GUID Partition Table) at MMC in u-boot. I plan to implement a separate command - gptrestore However, I think that one single command would be more suitable for this purpose. > or create separate commands: > > partuuid mmc 0:1 > part-get-bootable mmc 0 -- Best regards, Lukasz Majewski Samsung Poland R&D Center | Linux Platform Group