From patchwork Thu Nov 4 14:23:12 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Etienne Carriere X-Patchwork-Id: 516804 Delivered-To: patch@linaro.org Received: by 2002:ad5:5208:0:0:0:0:0 with SMTP id p8csp1993111iml; Thu, 4 Nov 2021 07:23:42 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzM8mQ8kQbKrBt2ASGtjvTZLkkXxJKkEdgmu9MvQNTXMTZJiisSDe8+g7IIQbsxNf9//Cgh X-Received: by 2002:aa7:c4d3:: with SMTP id p19mr27174018edr.333.1636035821815; Thu, 04 Nov 2021 07:23:41 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1636035821; cv=none; d=google.com; s=arc-20160816; b=hFmSK5fy3KG16xMYSj9bg2ufnVeX5+XkTNuoNigj6+xdBhvrHmbsymRHPtWTxREC2i KwZ3E/bUM2toqtqPrOKLsPjg6da5uxisjvMGH5oTYucVeUnoa9s4Pdzz7vbnGqguozfL aUU3dpLlfIVh9+sY39UQFs+6lms8FGi/Tnsuuij3Mpnorkx1jXfMylrfyv0J9VVTqTSI uAYAuBs21uNFkWu9n+ydHoZzwm22CxAdVTX4p7BNjACqRcBnbUGqoBeToejBEMUZbgWI ygXklkl1DTqwsBTMlxzQUwlc6nQKAhPrE3dFhyeSg6HWqAEzf3bOmeNTWHERfZtr/YLS sY7Q== 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:references:in-reply-to :message-id:date:subject:cc:to:from:dkim-signature; bh=JggBeFHHolj55WSUBAPxLNQxZcRtOj7nr8UyKpjH6LY=; b=xLYxmJvnn+SJF6PK/nzh7nBLBsdiMaf98dQBJ9SI8CugqsGydghVHDRurAnzbCJnNr a1h2i7ltGmPKYSJtvwyu4n+VgU4JCBX8AsDlyJrqSkeuUORyc3BMogoKFMT0ee15IHqL WzUznJb8xrFWE2QKLYFwHYnQwyvN0LnhGuKk3EpTBmOKH1pb0TQDK9uoJe5V2jJFPuwb AYhfvPspDIoulJDmL7X6+TCPvSGcefxnhkQQJJX3vYrG1JnbahlskW+N57TvKc6Lpn8k 8fd5uDGc72BS3xRHUmZfVAWeha/nn4bcpr10eTORRjyEOiEicE/H7AG207qVtz/jokXB m7qg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=fCqJEDCY; 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 c12si10339532edx.46.2021.11.04.07.23.41 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 04 Nov 2021 07:23:41 -0700 (PDT) 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=fCqJEDCY; 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 96FBD836D0; Thu, 4 Nov 2021 15:23:37 +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="fCqJEDCY"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id D6572836BF; Thu, 4 Nov 2021 15:23:33 +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 autolearn=ham autolearn_force=no version=3.4.2 Received: from mail-wr1-x433.google.com (mail-wr1-x433.google.com [IPv6:2a00:1450:4864:20::433]) (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 49ADB83686 for ; Thu, 4 Nov 2021 15:23:30 +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=etienne.carriere@linaro.org Received: by mail-wr1-x433.google.com with SMTP id b12so8909479wrh.4 for ; Thu, 04 Nov 2021 07:23:30 -0700 (PDT) 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; bh=JggBeFHHolj55WSUBAPxLNQxZcRtOj7nr8UyKpjH6LY=; b=fCqJEDCYCn88DJedJSpklrWfEFXgztagV73s2LD1+a5/3hzxgK49ZplOgYgazvC0HK kSfMW3XZ+PS8QNwfbvKOjW7VxRaW/cSrKPM99Hwdxeze7W370U+swlnsJxU6ZwJSuTVz y7mjbbgOclUCY33U8rHl9voWRWuCaVF34qJv3Iwk/2UdzfSJELFT1x+3kPfKe6NHhrnt cNzOWggMJ3v2j6V8u97k6Ml5YKbu/Z3N7pdGESIuzDrvBPI/9JbET4mQeOwuAxf/QRjZ XGr0CRaXydOOxzDrphmfc1UyKY++2/CuWOJmu45tLu265ltkH1hoRBEXxpimAO7H3Ear iRRA== 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; bh=JggBeFHHolj55WSUBAPxLNQxZcRtOj7nr8UyKpjH6LY=; b=DvQ3hR4n1qHW3Bkl5mttpAS/Tg9RU9EzXOq0jnQXq6tzFJ5J0GMDZyNRH857dwUW8V XLszovsCwrUPc5/35rPzl9XvumDz1mvM4CPiKYIEOS9UE/ptpYht7wovTIBFkb6oXwgG QbvZivWPeq6PbAbOcCz4RVLl8i+wLV3OVFof5VT8p6j2c636qQpcZKfiM3ykCJJBmuXF C9dF7ZEvcyCbXDYzLSVQCFJs5O8EZ42xnE0BFBiDTHFq2CoJvr4U3rhFlb/a2NFGwdGi JuMgbkfccVY4YE66PBeH/dM2RD2jVcH/ZJr0E7eVtGGMCiAMGRAPQ6j6LWCn0slPkcSI 0z0g== X-Gm-Message-State: AOAM533IjjSKVAXkTB1Z7QapuGtx97+1BGRBPKHq0PNGYYjNR9PqQ8fl z0OFBtxjyUDbOmgRDt8pIbRQr11x6MEs6A== X-Received: by 2002:adf:da44:: with SMTP id r4mr66982680wrl.180.1636035808765; Thu, 04 Nov 2021 07:23:28 -0700 (PDT) Received: from lmecxl0524.lme.st.com ([2a04:cec0:10b3:52ee:40ee:3a6f:5eb8:bd35]) by smtp.gmail.com with ESMTPSA id m34sm9383297wms.25.2021.11.04.07.23.27 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 04 Nov 2021 07:23:28 -0700 (PDT) From: Etienne Carriere To: u-boot@lists.denx.de Cc: Etienne Carriere Subject: [PATCH 02/14] firmware: scmi: mailbox transport: fix probe failure implementation Date: Thu, 4 Nov 2021 15:23:12 +0100 Message-Id: <20211104142324.2879-2-etienne.carriere@linaro.org> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20211104142324.2879-1-etienne.carriere@linaro.org> References: <20211104142324.2879-1-etienne.carriere@linaro.org> 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 Correct scmi mailbox probe function that can't free the scmi channel instance since its auto-allocated by the device model framework. Signed-off-by: Etienne Carriere --- drivers/firmware/scmi/mailbox_agent.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) -- 2.17.1 diff --git a/drivers/firmware/scmi/mailbox_agent.c b/drivers/firmware/scmi/mailbox_agent.c index ea35e7e09e..eb841d692b 100644 --- a/drivers/firmware/scmi/mailbox_agent.c +++ b/drivers/firmware/scmi/mailbox_agent.c @@ -72,17 +72,13 @@ int scmi_mbox_probe(struct udevice *dev) ret = mbox_get_by_index(dev, 0, &chan->mbox); if (ret) { dev_err(dev, "Failed to find mailbox: %d\n", ret); - goto out; + return ret; } ret = scmi_dt_get_smt_buffer(dev, &chan->smt); if (ret) dev_err(dev, "Failed to get shm resources: %d\n", ret); -out: - if (ret) - devm_kfree(dev, chan); - return ret; }