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 1670EC433EF for ; Wed, 2 Feb 2022 01:09:53 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 869C08340A; Wed, 2 Feb 2022 02:09:45 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (2048-bit key; unprotected) header.d=linaro.org header.i=@linaro.org header.b="x6JTsRpS"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id A1566830AB; Wed, 2 Feb 2022 02:09:43 +0100 (CET) Received: from mail-pj1-x1032.google.com (mail-pj1-x1032.google.com [IPv6:2607:f8b0:4864:20::1032]) (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 C350683845 for ; Wed, 2 Feb 2022 02:09:36 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=fail smtp.mailfrom=takahiro.akashi@linaro.org Received: by mail-pj1-x1032.google.com with SMTP id h20-20020a17090adb9400b001b518bf99ffso5212375pjv.1 for ; Tue, 01 Feb 2022 17:09:36 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=Y76P07ukuT1wREwWJsiB4J82LPFAi8f0WyRnmBNx5ts=; b=x6JTsRpSTjCZaRSO3afW26E2YX/mv/hW7pEnVjzAknyl/5+yqdtjNP0UVzS0PM4LNg 9dKPkHLw+ofdFFyH4dqV1B33u11L13/7Mni64GA51uatGS0TjfG7t7W+7Qptkhndr/c1 q7YtdebnVGOfRGi3YsFN3PPbLcGClSUajAr2EWQ0YDx4RtK0roi0mRX2B1EGx8YNLqrx ktvOm6OlsNWmgjvPBlb0kU2BsYI7lYxSN2lajvIBEPhDTTGlIVwfAetfBWqtquxfDtfY a0QqtAT84aULApVAhqIiwTLzDztFCwLcLXNMKmBPNENONxWRCc46xkUjUVORpKBXGTjB DyTg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=Y76P07ukuT1wREwWJsiB4J82LPFAi8f0WyRnmBNx5ts=; b=0SERMVCw6CMjKSdjij02s89SKFdi/4OqZwwXzRVvLA1VUJUh58zLVDHRD72ybbafEy F7MwmZMuYxlA8xCIZ2GskrFAtG27sNIEQ4PMn/1CIZ65kxIPvFqfuM7Eb4o4wM36/rkU 74zSQdKE2XpXxobDHoP42O7xwL249CI4nLVN4/L33jvbls1x9UsUXAYRxY2bQlQhZedQ +iS8vYH8h+BBrxqGq9BGavkg9BawPL5BnpVo9LcZGb3VWp6zecle+3Qe4HWdfLvbLZPb 0btPh/0qGetNVjDYmmmJbchK1Qi1iIHNgsZrG6EPFHFA5YDd9Ha+GPawtzYAXZveum6t EAXg== X-Gm-Message-State: AOAM531YCSWEWaBOZmeazh5nPFNdje6AdRCtqMXMrlSUUb/lKdGo3sws IBytJWrQGO40eZC1P5uta8UyYg== X-Google-Smtp-Source: ABdhPJyth5KxzoyyCyU7RKQSxCzp7IPQH5bhpa0RRH7oGwNqgaUfCt6LSSxUrL6D/SuRSC8YUQUG7Q== X-Received: by 2002:a17:902:e852:: with SMTP id t18mr28386494plg.104.1643764175225; Tue, 01 Feb 2022 17:09:35 -0800 (PST) Received: from localhost.localdomain ([2400:4050:c3e1:100:314e:b83b:fa90:7f2e]) by smtp.gmail.com with ESMTPSA id f5sm10761429pfc.0.2022.02.01.17.09.32 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 01 Feb 2022 17:09:34 -0800 (PST) From: AKASHI Takahiro To: lukma@denx.de, peng.fan@nxp.com, jh80.chung@samsung.com, bmeng.cn@gmail.com, peng.ma@nxp.com, sr@denx.de, xypron.glpk@gmx.de, sjg@chromium.org, ilias.apalodimas@linaro.org Cc: masami.hiramatsu@linaro.org, u-boot@lists.denx.de, AKASHI Takahiro Subject: [PATCH 02/19] usb: storage: call device_probe() after scanning Date: Wed, 2 Feb 2022 10:08:36 +0900 Message-Id: <20220202010853.40405-3-takahiro.akashi@linaro.org> X-Mailer: git-send-email 2.33.0 In-Reply-To: <20220202010853.40405-1-takahiro.akashi@linaro.org> References: <20220202010853.40405-1-takahiro.akashi@linaro.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 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.5 at phobos.denx.de X-Virus-Status: Clean Every time a usb bus/port is scanned and a new device is detected, we want to call device_probe() as it will give us a chance to run additional post-processings for some purposes. In particular, support for creating partitions on a device will be added. Signed-off-by: AKASHI Takahiro Reviewed-by: Simon Glass --- common/usb_storage.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/common/usb_storage.c b/common/usb_storage.c index c9e2d7343ce2..291728f37e0a 100644 --- a/common/usb_storage.c +++ b/common/usb_storage.c @@ -239,6 +239,10 @@ static int usb_stor_probe_device(struct usb_device *udev) if (ret) return ret; } + + ret = blk_probe_or_unbind(dev); + if (ret) + return ret; } #else /* We don't have space to even probe if we hit the maximum */ -- 2.33.0