From patchwork Tue Mar 8 11:36:44 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: AKASHI Takahiro X-Patchwork-Id: 549274 Delivered-To: patch@linaro.org Received: by 2002:a05:7000:6713:0:0:0:0 with SMTP id u19csp2539621mag; Tue, 8 Mar 2022 03:39:37 -0800 (PST) X-Google-Smtp-Source: ABdhPJzybjwS/c7+KSHELds79ODSmDK3PcGYnT/2/alOA8V+mzILy2Do/1VauP136M/Zr1TEAD0u X-Received: by 2002:a17:906:7315:b0:6da:820d:4e02 with SMTP id di21-20020a170906731500b006da820d4e02mr12886028ejc.65.1646739577607; Tue, 08 Mar 2022 03:39:37 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1646739577; cv=none; d=google.com; s=arc-20160816; b=d8HtgSNCm9yS2QZHFCKnmhrdp2JZ46egH0EC2upSGLjo53X5YqAK0HoCEC1QsVjrqU 5oqIE3JFDgmLS01oqMSzupRCd9EXAcGnWDEMdZLB+AhHVL45CCCRxJY2R+vUnk6hvWJM /eZGXkbyZTTK0+Kq6jvTuRUWeo0NduDCZvxJokvzWpMhR+9UXp5QU475yMFyqJbZAgVI Oucrp8/j0m3t61mm76Gr6xlxkC1irRAyD3VBeVR4E/Ws7YRAhexI4kC76/uxEnIOo/J6 Ybq+bTL0Cf+TkQJTI2ZXAcPw1EM4gNvO0NfI/xUC/PXBqoujdrWsJlPmz8IJLjvmP7S0 G3sQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=21p8MTYNF7aSvYArLa/oCYJtojleEgemMQex/7JFzDI=; b=Nwy7/V31b2QDPEylCuP7+qta5/y20dslf5bEcQpRJzjRNOg/phmioRSumUn5+EVK97 Mcr5EveFj3d//cwvsg6HPgJ8fwBddSylrSc1KrAGHVgUYTh/CuQOJzK/IKCNAHd/kxKb iCZdcUZQHqSatwmTd8YVdYX+eLz9yQMi42xiP+SWfiirwWH8+rJqB84s1d8xnclJln0U Yg8QF9lAKypR5msdER553IjRsTPfLBv7emRNxkcKsfLqa9wJ2dtB3aVBdOwgufSe2NYo uKCiRdrw3NcQgURjGUaqKTDB9dqtm38ewBP8XZybMUuRVtF7Kf/RzQKaE2Yw11EYmpFk J9OA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=wLjvJEcn; spf=pass (google.com: domain of u-boot-bounces@lists.denx.de designates 2a01:238:438b:c500:173d:9f52:ddab:ee01 as permitted sender) smtp.mailfrom=u-boot-bounces@lists.denx.de; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from phobos.denx.de (phobos.denx.de. [2a01:238:438b:c500:173d:9f52:ddab:ee01]) by mx.google.com with ESMTPS id zj24-20020a170907339800b006b51c81ffe2si10221686ejb.938.2022.03.08.03.39.37 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 08 Mar 2022 03:39:37 -0800 (PST) Received-SPF: pass (google.com: domain of u-boot-bounces@lists.denx.de designates 2a01:238:438b:c500:173d:9f52:ddab:ee01 as permitted sender) client-ip=2a01:238:438b:c500:173d:9f52:ddab:ee01; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=wLjvJEcn; spf=pass (google.com: domain of u-boot-bounces@lists.denx.de designates 2a01:238:438b:c500:173d:9f52:ddab:ee01 as permitted sender) smtp.mailfrom=u-boot-bounces@lists.denx.de; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id C7072839AE; Tue, 8 Mar 2022 12:39:26 +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="wLjvJEcn"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id A1B15839AA; Tue, 8 Mar 2022 12:38:44 +0100 (CET) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on phobos.denx.de X-Spam-Level: X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS, T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.2 Received: from mail-pf1-x42f.google.com (mail-pf1-x42f.google.com [IPv6:2607:f8b0:4864:20::42f]) (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 36B0F83919 for ; Tue, 8 Mar 2022 12:38:05 +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=takahiro.akashi@linaro.org Received: by mail-pf1-x42f.google.com with SMTP id g1so17119576pfv.1 for ; Tue, 08 Mar 2022 03:38:05 -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=21p8MTYNF7aSvYArLa/oCYJtojleEgemMQex/7JFzDI=; b=wLjvJEcnnLnOm+hy8kEjDRmhVfEaBZJ2PjUivnyHPHxsC7mLgJnk3zyd8tuYmgJEdz cd7wyQCIA3wWFT2gAUtb/i/krNSBlzjfhWpET4pzY54xe0hydh63pWAmWJ6SSdyLDR1u Ed2vRD1XLvsJLI5WJTG9sE/cSfmXzkkAP6dMWSBvGgn00pRwmHA9qe+5nMmMk9LG14Y0 XKnjIINd0uEmTtd/eQ6a+0uJxBXeR8k2OdiHrmVEsrwKxzPPKDe7bsbeoGEyaLr9Z8ec W92BSpQ7YneAJUig2WdF2Y7CawZliLmOEWPBWS+rLnkQ97WY7NmgueGGUmqWcx/6Ke4n AHMA== 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=21p8MTYNF7aSvYArLa/oCYJtojleEgemMQex/7JFzDI=; b=nIOCdF7S2w+z0QqrVQ+8qhOa5Q2nm7NeRzVw/jKO0xV5p5I809C0uCjjnD1mgmI6bz CKtfU6rJXK6NewUBdNOFRqK1HMEZ+evmCaIVKnC9jKfhkVZvyAOqkat5a9SxIgPBGzpI sMDXcNnQv8VWfdb1MRQ94Ctdj+WoLSQLyoVllduJOaJdZWNvXgRURZu376Pj6GbtiUTk eG4UBgK7c6JS1gBX3zMMGGKJDxwYgOMqw3to2oIwjY+ZqIrD5Rl43bNo30qrbIuuatSi Smh6S/QmYyqSkfTv1MRMXIpUOysZEiMlmwWNC7rj80Ozd7JTIJylLkgjMKWGbrAlXZYV +rKw== X-Gm-Message-State: AOAM533cl0b9O3Uvm4jAs18vkaeiwWkQy1Dfnqw1CZd2neG6rOrw07B5 AdvxB0VEx+jV5V/pdCJV6BIJ7Q== X-Received: by 2002:a05:6a00:984:b0:4e1:5e1b:1e9b with SMTP id u4-20020a056a00098400b004e15e1b1e9bmr17643004pfg.71.1646739483600; Tue, 08 Mar 2022 03:38:03 -0800 (PST) Received: from localhost.localdomain ([2400:4050:c3e1:100:b94a:f47a:3d51:185c]) by smtp.gmail.com with ESMTPSA id z2-20020a17090a170200b001bf2d530d64sm3434677pjd.2.2022.03.08.03.38.00 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 08 Mar 2022 03:38:03 -0800 (PST) From: AKASHI Takahiro To: lukma@denx.de, peng.fan@nxp.com, jh80.chung@samsung.com, bmeng.cn@gmail.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 v3 06/19] block: ide: call device_probe() after scanning Date: Tue, 8 Mar 2022 20:36:44 +0900 Message-Id: <20220308113657.221101-7-takahiro.akashi@linaro.org> X-Mailer: git-send-email 2.33.0 In-Reply-To: <20220308113657.221101-1-takahiro.akashi@linaro.org> References: <20220308113657.221101-1-takahiro.akashi@linaro.org> MIME-Version: 1.0 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 an ide 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 --- drivers/block/ide.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/drivers/block/ide.c b/drivers/block/ide.c index 63c4cfdc1c21..e8518ff3a11a 100644 --- a/drivers/block/ide.c +++ b/drivers/block/ide.c @@ -1123,6 +1123,10 @@ static int ide_probe(struct udevice *udev) blksz, size, &blk_dev); if (ret) return ret; + + ret = blk_probe_or_unbind(blk_dev); + if (ret) + return ret; } }