From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752098AbaDAVsp (ORCPT ); Tue, 1 Apr 2014 17:48:45 -0400 Received: from mail.kmu-office.ch ([178.209.48.102]:44691 "EHLO mail.kmu-office.ch" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751792AbaDAVsn (ORCPT ); Tue, 1 Apr 2014 17:48:43 -0400 MIME-Version: 1.0 Content-Type: text/plain; charset= Content-Transfer-Encoding: 7bit Date: Tue, 01 Apr 2014 23:46:33 +0200 From: Stefan Agner To: Stephen Warren Cc: chris@printf.net, linux-mmc@vger.kernel.org, linux-tegra@vger.kernel.org, linux@arm.linux.org.uk, linux-kernel@vger.kernel.org Subject: Re: [RFC 2/2] mmc: use SD/MMC host ID for block device name ID In-Reply-To: <533B25E8.8040201@wwwdotorg.org> References: <2f6ac51155f9d34791b274b5102d15a997ff8b99.1396384101.git.stefan@agner.ch> <533B25E8.8040201@wwwdotorg.org> Message-ID: <837c304930e6ea74db848c14c6fa6313@agner.ch> User-Agent: Roundcube Webmail/1.0-rc Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Am 2014-04-01 22:47, Stephen Warren wrote: > That's not true. There's no guarantee that a device name/ID gets > released as soon as the SD card is removed; something might still have > it mounted for example. Yes. Also when booted there are other solutions to get static block device name (e.g. /dev/disk/by-path), but the problem at hand aims for a solution for the root file system. Also, eMMC don't get removed, and those internal eMMC devices are the reason of this thread... (see cover letter) > The correct solution here is to use filesystem or partition UUIDs to > identify the device/partition, not to attempt to assign static device IDs. Yes, I'm aware of that solution. However, when recreating the partition table, those UUIDs do change, which in turn needs a change of the kernel arguments. Of course, one can use scripts to work around this, but its easier to just boot from the block device at a given location (say eMMC, first partition). Then, using UUID is also not as fast as using a device name directly, since all block devices get scanned. This is not optimal when trying to optimize boot speed, but might be negligible. I actually never measured that. There are the /dev/disk/by-path/ which aim at a similar goal, but those names are generated by udev. I'm open to suggestions solve this issue in a more fashionable way...