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 mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 04591C433EF for ; Mon, 11 Oct 2021 01:12:09 +0000 (UTC) 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 mail.kernel.org (Postfix) with ESMTPS id 3A61660F6E for ; Mon, 11 Oct 2021 01:12:08 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org 3A61660F6E Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=linaro.org Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=lists.denx.de Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id DF06583578; Mon, 11 Oct 2021 03:12:05 +0200 (CEST) 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="j5TDnwkj"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 53626836B9; Mon, 11 Oct 2021 03:12:03 +0200 (CEST) Received: from mail-pj1-x1030.google.com (mail-pj1-x1030.google.com [IPv6:2607:f8b0:4864:20::1030]) (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 C260E8354E for ; Mon, 11 Oct 2021 03:11:58 +0200 (CEST) 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-pj1-x1030.google.com with SMTP id oa4so11291048pjb.2 for ; Sun, 10 Oct 2021 18:11:58 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=date:from:to:cc:subject:message-id:mail-followup-to:references :mime-version:content-disposition:in-reply-to; bh=Rxu0VySzaRAtlmAwxBLYXWMRbKCBC8L4qjPPYCObkcQ=; b=j5TDnwkj0YYPrLeWQOCLv+W95mhxTZbsJrtlNtk5ieHfnBmBo3HRQQFLEQD4ol+NJm UOadsUUUJ5j5KTALAqhu5G+HImp2F4RHrw9XEJQ70vEQowVSWwXX2A0aMFERzNIUhjex Gt7wRhn2bGqKblEiS/BIpLYhXHx9RTQ1nLdQd4TVIJCzVhQJ8zllKWmnj5fZTPJBXIL4 i9AJl7A9V9oQCodpfWzVAeJok3uzvJgUYwxE55lG+JF+Zlotc+C32tStJmnaQOnBtUNr ZHcIFJW9WrH0faq/Ee0VTcrNP3sdqKbPxhHf5ZYScUzlLFvoFiZryqksEyNcHjB6/fmi c44w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:date:from:to:cc:subject:message-id :mail-followup-to:references:mime-version:content-disposition :in-reply-to; bh=Rxu0VySzaRAtlmAwxBLYXWMRbKCBC8L4qjPPYCObkcQ=; b=ViXOO/zrdVyKJANinNvKW2gfmljKwCFPXzsgZWiouDNERRaaY5xEvLSvBNluCseWZF Kp4BPljmwzriLGzh4tkBDW2V/YnR48/gNvVjqnYt6MATqxlBlaRt9cJfzFPB7EA652m+ RX27LxowsmM2xpDr+r09IIIhswDygGH0+gVyzHNQ1M3nb/OyS3fmnscxCWV734guOJhL 5AmSc+0NvqUViXLKYfTTg4rkFQNtdnSgr08spexgzWLAnMBs9PUKoZhKMt7FEapQmf3m SphmMjc4ntwGKXSjHXSVKrZbzEpodfVcNRY2gxinjzUbeyvuP+ZDUMjZE9IoFJ258zHq gZEw== X-Gm-Message-State: AOAM532JxYIhGhy1nEhq9JcxYsJ/BQntzfHBihwoq9wY5fxrvVttb538 enNHW2r9Tbg7qhR/SvPlYFPLlg== X-Google-Smtp-Source: ABdhPJxbzwqZDXpSlUjwxQCotFidOVy0QGjD3hBoSpsGMblzJpIaJNXIJNQOwrrfvP3dkJZH8o1agA== X-Received: by 2002:a17:902:e144:b0:13f:4b7:68c0 with SMTP id d4-20020a170902e14400b0013f04b768c0mr21586226pla.77.1633914716888; Sun, 10 Oct 2021 18:11:56 -0700 (PDT) Received: from laputa (122-100-26-39m5.mineo.jp. [122.100.26.39]) by smtp.gmail.com with ESMTPSA id a13sm6134582pgn.81.2021.10.10.18.11.53 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 10 Oct 2021 18:11:56 -0700 (PDT) Date: Mon, 11 Oct 2021 10:11:51 +0900 From: AKASHI Takahiro To: Simon Glass Cc: Heinrich Schuchardt , Alex Graf , Ilias Apalodimas , U-Boot Mailing List Subject: Re: [RFC 06/22] sata: call device_probe() after scanning Message-ID: <20211011011151.GC44356@laputa> Mail-Followup-To: AKASHI Takahiro , Simon Glass , Heinrich Schuchardt , Alex Graf , Ilias Apalodimas , U-Boot Mailing List References: <20211001050228.55183-1-takahiro.akashi@linaro.org> <20211001050228.55183-13-takahiro.akashi@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.34 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.2 at phobos.denx.de X-Virus-Status: Clean On Sun, Oct 10, 2021 at 08:14:12AM -0600, Simon Glass wrote: > Hi Takahiro, > > On Thu, 30 Sept 2021 at 23:03, AKASHI Takahiro > wrote: > > > > Every time a sata 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 > > --- > > drivers/ata/dwc_ahsata.c | 10 ++++++++++ > > drivers/ata/fsl_sata.c | 11 +++++++++++ > > drivers/ata/sata_mv.c | 9 +++++++++ > > drivers/ata/sata_sil.c | 12 ++++++++++++ > > 4 files changed, 42 insertions(+) > > > > diff --git a/drivers/ata/dwc_ahsata.c b/drivers/ata/dwc_ahsata.c > > index 6d42548087b3..6a51c70d1170 100644 > > --- a/drivers/ata/dwc_ahsata.c > > +++ b/drivers/ata/dwc_ahsata.c > > @@ -1026,6 +1026,16 @@ int dwc_ahsata_scan(struct udevice *dev) > > return ret; > > } > > > > + ret = device_probe(bdev); > > + if (ret < 0) { > > + debug("Can't probe\n"); > > + /* TODO: undo create */ > > + > > + device_unbind(bdev); > > It looks like this one has the wrong variable name. Ah, it was a copy-and-paste thing :) I will fix it. Thanks, -Takahiro Akashi > [..] > > Regards, > Simon