From patchwork Fri Apr 15 07:15:35 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: AKASHI Takahiro X-Patchwork-Id: 561937 Delivered-To: patch@linaro.org Received: by 2002:a05:7000:6886:0:0:0:0 with SMTP id m6csp114992map; Fri, 15 Apr 2022 00:16:26 -0700 (PDT) X-Google-Smtp-Source: ABdhPJy9eOGDfDiMZvqKJI8ko5Y6tKjhdBNG1oZH/22SMeQV3umachaw6I2ImaTKPBOD2w3ASC0A X-Received: by 2002:a17:906:58d3:b0:6da:bdb2:2727 with SMTP id e19-20020a17090658d300b006dabdb22727mr5166025ejs.549.1650006986729; Fri, 15 Apr 2022 00:16:26 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1650006986; cv=none; d=google.com; s=arc-20160816; b=U/EL9AFAivmkXw+kWQ8VUZfEZ9781/2XK1BzdeYT84szsEM2vv/zw5uqLHyOjhoho3 pmni2Lu0kctp4mKnV4L/6cGKN2Afj+ytjzV/7an2yXaSTRl6xY9avN77ilLpAtRddDin KZuIEWCGeuaTNXRCaITHp0Sb/jyPpyBfCC01O50L9arblOBV5+rfLzvFU7A6QlQlc24U F7oHCZUkw/FNae96d8W5xpGEJwhh+G27dzvb7jUuilcvnTRyAp0VdfEcw6oj/Lq/dlL5 Brogz4PXCUbwTizaj3jnFuE8e301WW7wJm4TuzSwkDIhSM2yeSqMstGBgRoliIUYesW4 ErHw== 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=yPlc4gJGW0AhXRY0zwO1CjBS+z1fQTk36P+/M080M4Q=; b=ZKNauYgHFCk4hOUrxya9O+8I+VDTJrOJ8GaRnW+SYsAT6b4ZQe2q6xAKWCqYA/KKkZ /u62YbAodU/jrZHHQDc66+10I0Z0OKGP27cp+60DfyUjOQzDGwtW6gSjFjL8QTRoFvDv vPPE7SbHrpm0H+blravPeVH2MKzioIBMp3X5oTdbnR8+rZE68Y/h2s+jz7cXnIEb3U1N 1moAJHiU9S32WpwF4NTT45sb5cd33Q8HM6feRtnhdIVFlAdQZiuT+OMqnoZ1vdLsSf0o 50XRJ/RhUNAp8PsrRaoziGFKpFlJ+YXDZ4cxGLPqZc9NuQheMtn1VGIZrynlZc3mmYwJ hHow== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=ZP1op1+v; spf=pass (google.com: domain of u-boot-bounces@lists.denx.de designates 85.214.62.61 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. [85.214.62.61]) by mx.google.com with ESMTPS id f12-20020a170906824c00b006e834cdabedsi533315ejx.291.2022.04.15.00.16.26 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 15 Apr 2022 00:16:26 -0700 (PDT) Received-SPF: pass (google.com: domain of u-boot-bounces@lists.denx.de designates 85.214.62.61 as permitted sender) client-ip=85.214.62.61; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=ZP1op1+v; spf=pass (google.com: domain of u-boot-bounces@lists.denx.de designates 85.214.62.61 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 2DC21839C3; Fri, 15 Apr 2022 09:16:22 +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="ZP1op1+v"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 0204E839B9; Fri, 15 Apr 2022 09:16:21 +0200 (CEST) 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=ham 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 44E5983941 for ; Fri, 15 Apr 2022 09:16:18 +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-pf1-x42f.google.com with SMTP id l127so4983683pfl.6 for ; Fri, 15 Apr 2022 00:16:18 -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 :mime-version:content-transfer-encoding; bh=yPlc4gJGW0AhXRY0zwO1CjBS+z1fQTk36P+/M080M4Q=; b=ZP1op1+vfbGDSw08dFaTHoVLmL3TiiHbYXwnK+fYlQnqOo906m48rIA/knUUEVroEj 0VszAKtLd1nw7RMFtm/D7phE8Ld208YWUhPV29tJ/yGiejkKg9EOdWsGag4Z5thM7MW7 bqJs3u+Ajtjr8NbALbzq+cSNrsU+NlxBn9Uu8vcgnef0AEWKNAbP61u+17kKoDqKlwKV iBxbPQyunCaIahuuepCa4p5M2HQM6fLNMDVef+5xFx8FOUDqOq1ZDIKq6ExTLowNxTze Bnu18ONFQiryMNwWR+krVPIqij3gjcbzFRQEmGTyYCIyWxjMolRtYOgfqyTXMCV++VYt Q46Q== 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=yPlc4gJGW0AhXRY0zwO1CjBS+z1fQTk36P+/M080M4Q=; b=CDq07QhUa05Vn5XFVMVXJPFv/imNLTFa2A0BH2dlBPdtIUOT3hJHyMMvWbVe3Nap8J 4aIjpwii7uwUiCYJvvNUzNLt+cELf+VyQsrPevsJX2D/Nt0kyplhH5AtxBppz/jJ1AyH lXcQt5QUjXaiG2HctcsjldHfuSULEuPLbpWkyFWCeFn9Vsogck4TITJ5LQB9TW6N0+cH Xv3M2cVTg+zDK6J/yDiu9gMiOLAu8P+TOMVK82ohsPAFkFVuCP406aDCPJn8n9Qcknyz sU5SxJHutl/svXOBJO1PgpFlRJqEaNcWrSsXJxlwsKiPZ17IWhtVBvjxQKLxWyODzBkZ SSAQ== X-Gm-Message-State: AOAM530czLmrTIe1KcpiepnlmYZMjuKF/lJw3HP17giL0NYruUegP9Nq MeTZVb5bwJzsNqZfH36nu4BN9g== X-Received: by 2002:a05:6a00:140c:b0:4e1:530c:edc0 with SMTP id l12-20020a056a00140c00b004e1530cedc0mr18543378pfu.18.1650006976687; Fri, 15 Apr 2022 00:16:16 -0700 (PDT) Received: from localhost.localdomain ([2400:4050:c3e1:100:18f3:1e4:6c4:6ea3]) by smtp.gmail.com with ESMTPSA id p1-20020a17090a0e4100b001ce188720e5sm3566921pja.53.2022.04.15.00.16.14 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 15 Apr 2022 00:16:16 -0700 (PDT) From: AKASHI Takahiro To: 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 v4 01/12] dm: tag: change ENOSPC to ENOMEM Date: Fri, 15 Apr 2022 16:15:35 +0900 Message-Id: <20220415071546.122475-2-takahiro.akashi@linaro.org> X-Mailer: git-send-email 2.33.0 In-Reply-To: <20220415071546.122475-1-takahiro.akashi@linaro.org> References: <20220415071546.122475-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 ENOMEM is a more common error code for memory starvation. Signed-off-by: AKASHI Takahiro Reviewed-by: Heinrich Schuchardt Reviewed-by: Ilias Apalodimas --- drivers/core/tag.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/core/tag.c b/drivers/core/tag.c index 6829bcd8806c..22999193a5a3 100644 --- a/drivers/core/tag.c +++ b/drivers/core/tag.c @@ -29,7 +29,7 @@ int dev_tag_set_ptr(struct udevice *dev, enum dm_tag_t tag, void *ptr) node = calloc(sizeof(*node), 1); if (!node) - return -ENOSPC; + return -ENOMEM; node->dev = dev; node->tag = tag; @@ -53,7 +53,7 @@ int dev_tag_set_val(struct udevice *dev, enum dm_tag_t tag, ulong val) node = calloc(sizeof(*node), 1); if (!node) - return -ENOSPC; + return -ENOMEM; node->dev = dev; node->tag = tag;