From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 27572C32771 for ; Fri, 16 Sep 2022 01:31:59 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id D934B84BA7; Fri, 16 Sep 2022 03:31:24 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.b="PFhurtez"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 01FC48494D; Fri, 16 Sep 2022 03:31:06 +0200 (CEST) Received: from mail-yw1-x112a.google.com (mail-yw1-x112a.google.com [IPv6:2607:f8b0:4864:20::112a]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 5776C84B4D for ; Fri, 16 Sep 2022 03:31:03 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=sjg@google.com Received: by mail-yw1-x112a.google.com with SMTP id 00721157ae682-3452214cec6so242104677b3.1 for ; Thu, 15 Sep 2022 18:31:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date; bh=JNIXEEwPn00JHuQrmJ+aCJxCPSme9/jqs2GxdqbZNqE=; b=PFhurtezeihUJzQMJ0MyB/y6J/vbqWV9wf1x9tWbfFZdUvG2IKJeWVWy7Nurj/ab6g 9jTNLYLyP0AyKy8a5wXNvCYherxYE75bBhhyE3xsk7D3f0yxOyuuuyxAcgoQFcaGQrgE lNdWuPVoPzGuVO0RTlzrl5DtCAiCKJXFkM2VY= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date; bh=JNIXEEwPn00JHuQrmJ+aCJxCPSme9/jqs2GxdqbZNqE=; b=dSIOJH6KqasbZD6mEkqqDlPR24rf6YtDtMpIFU3zGc1ytfiD5Smig35RcuSbwBmbDX v5Gv3cCshSFbAEk/PCffy63hWhb6Szgr2/ym0/LB5xoXETeEPyEmRBMIvTbGM+RlwuKX qM3X7oSl/UC8FWQMjonD7xvXP7Qa9ne8rC4TUN3eqBX3aqsApDbQIUsyqwpwMGLz2vGQ RFT4ZLh6qM2+y8mBqCGQSemJyCe5Wwce34AKywB1DygKWvnLcvVy3PmFKElSs1eKXjod VbqcfT84pbD2iBA0WNtgzOunYD6Pem1F5kPOjHXCMeXZ6+38ayzfraowZhia+NXG8twc po2A== X-Gm-Message-State: ACrzQf2rNckLnqF1cWYqCVJYDNNhnta44QPsbkJgQ1VYlcASiAfLJB3a ktu0QAhgVjBPRKT9IelSg2fb1SNooHQG/PQV6elCgw== X-Google-Smtp-Source: AMsMyM6ekcdc9a2c83HjKNp/tMhYoAARnth64PfYcWE82VdaJFxqXjj3NfCBV7zqVGbtGGe35O5jnJuqALfT+dJVXDE= X-Received: by 2002:a0d:d883:0:b0:346:88b5:f4ff with SMTP id a125-20020a0dd883000000b0034688b5f4ffmr2392755ywe.355.1663291861255; Thu, 15 Sep 2022 18:31:01 -0700 (PDT) MIME-Version: 1.0 References: <20220915200242.18358-1-heinrich.schuchardt@canonical.com> <20220915200242.18358-2-heinrich.schuchardt@canonical.com> In-Reply-To: <20220915200242.18358-2-heinrich.schuchardt@canonical.com> From: Simon Glass Date: Thu, 15 Sep 2022 19:30:48 -0600 Message-ID: Subject: Re: [PATCH 1/2] dm: blk: assign media ID to block devices To: Heinrich Schuchardt Cc: Ilias Apalodimas , AKASHI Takahiro , Masahisa Kojima , U-Boot Mailing List Content-Type: text/plain; charset="UTF-8" X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.39 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.103.6 at phobos.denx.de X-Virus-Status: Clean Hi Heinrich, On Thu, 15 Sept 2022 at 14:02, Heinrich Schuchardt wrote: > > Currently block devices are only identified by uclass_id and device number. > When dealing with removable media this is not enough to uniquely identify > the medium. > > E.g. after host unbind, host bind we can have the same device number but a > different backing file. > > The EFI specification uses a 32bit number media ID to identify media. Add a > matching field to the block device descriptor. > > Signed-off-by: Heinrich Schuchardt > --- > drivers/block/blk-uclass.c | 16 +++++++++++++++- > include/blk.h | 11 +++++++++++ > 2 files changed, 26 insertions(+), 1 deletion(-) Shouldn't this be handled by connecting the EFI data to its udevice. I think Takahiro has been looking at this? NAK to any EFI fields in blk_desc, in any case Regards, Simon