Received: by 2002:a89:d88:0:b0:1fa:5c73:8e2d with SMTP id eb8csp2004363lqb; Mon, 27 May 2024 05:04:28 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCW6sT//c0dDd1HbYqWh6q2Na8+aTmdBMGDa7xleye1QVf9pyCkLy4o6+4U9EBH0oyhDBEPtRd5afsHiq2WyFzZRcrgG4panlDPnwU3q0A== X-Google-Smtp-Source: AGHT+IGavrUGA/a2ZJ0FaI2N+p+kdNZWrRWQPyhyBVOkGgBLB1cqs8xXvPQ7EOjia/4wB5hnPtI7 X-Received: by 2002:a17:902:efcc:b0:1f3:a22:7c4e with SMTP id d9443c01a7336-1f4486f23b7mr65689235ad.17.1716811467843; Mon, 27 May 2024 05:04:27 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1716811467; cv=pass; d=google.com; s=arc-20160816; b=RVWQt0dkBvg0CRl/O4YFdC6miqAxrJbLlWK4AL15gp3Lldv3eaZCCS/V6ZnHRMKtNS BzxwaHjXSYI3+2ziB6neTrUpTPB7j+gjveYzb/EWWE6rxRsRFYBJuQH4N8dHqJ/xTzIx aettLGnle06SvnLDxZSSV7j2we/SuUJpGHN6v+43ddG8wvRppQQvQOuT2P9h1Ww9KkEj PSPR2IR9laO8GU1U2hBxzLG0nf8LdLU0DVqNTs/o+mWFce+7SRCc/tgoCWAH5wWsi2qP AjBOyghmaAxJYzit9lbIbrwyR8xeFcmcqYVY7Eo8XZ7wEiO0jMNg/9yxFw7hhttOVjlu lxUw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:in-reply-to:autocrypt:content-language :from:references:cc:to:subject:user-agent:mime-version :list-unsubscribe:list-subscribe:list-id:precedence:date:message-id :dkim-signature; bh=cXwF7fyL6fAorVK1Mie0pfmyxORVWeiwCc+aS9Z2qEE=; fh=XGjEV1TYYDaWEOXxPLK+N/fEevL8WiM5GHpYblV87iw=; b=qSLn5+uICKXf5z2T5O4xQbKV1i3mn7Pr+lQvAsoTfvAK7Kes2ZAnv55HPpKPGZmbmx T9iCDc7JQr4EYyEja6XEG2i7uQNVigQNKwtENztxAxV8lJsAxSL6G+SZGC7GpWvghvL9 7MgNi20XxTM951fO7UHgpttFmgUD6gzGO+sDhpIObVZAKmuSGHMvPih1rbDpQxhotiTi 2Y/3VKWpz1CZ4wNtvwt3mE9aqikGaFb3G6w4fSq5xo8U5AwVruHdL7P2aFaYPfuSdW21 52jhlrCYZ9b+Jk0n4JxHMPy1OTXt2ptLlkZOEwjpi2K/zFx8Bxm9Wk/jHfe+Z+9vJ6F6 jBww==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=ERsaGHCz; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-190515-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-190515-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [2604:1380:40f1:3f00::1]) by mx.google.com with ESMTPS id d9443c01a7336-1f44c7891dasi59089055ad.101.2024.05.27.05.04.27 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 27 May 2024 05:04:27 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-190515-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) client-ip=2604:1380:40f1:3f00::1; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=ERsaGHCz; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-190515-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-190515-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sy.mirrors.kernel.org (Postfix) with ESMTPS id 265C8B244A8 for ; Mon, 27 May 2024 11:52:32 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 1075A15DBCE; Mon, 27 May 2024 11:51:22 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="ERsaGHCz" Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 327661581E2 for ; Mon, 27 May 2024 11:51:20 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1716810681; cv=none; b=nWg5gm2DbU89kqxUKLaLtDgvkULFGJSJkrK1Td2slIcUjRY/J8QIj/SfTG/ve19qaSd40oaKn5gpe8GlmWGwMEFVJvduDHaZPmWaYvKujy/FfeTEnSyWIyMdkvNzRimqy3hA39PlXDNQMiDM6th7/dirkN6ja0w+sQcwiAYf3us= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1716810681; c=relaxed/simple; bh=43ClAfanCjo/Nplmn1TBB+mwgik97Zqnc6FL9jHRtPk=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=XUf+mjjyzidD1PyMgGdQbN35va8UIncWB+jG2YIBgOodf8tRrD1/uoz1IaM9P8RLtrr5Vs4NCp1Inum1CpndY0IgU0TMDhVg5n6dC+FTIAvXleJ2JQhOl283dpdvEt755NWVQCw7igO722FJu/Ot+v6XNZdkitXb0JBwL80JbDg= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=ERsaGHCz; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id 047FBC2BBFC; Mon, 27 May 2024 11:51:19 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1716810680; bh=43ClAfanCjo/Nplmn1TBB+mwgik97Zqnc6FL9jHRtPk=; h=Date:Subject:To:Cc:References:From:In-Reply-To:From; b=ERsaGHCzYiWdgBKGrc/BO4piw18+z/0aKDEAR8wt+Dpeb+icy3+7JcFTHogL+Rcow chA6qHA5UVBIz0f6PWZANi6atnnKwpnrYqH00BsyyQRhJl4FhQ/u/mNjyQjxSb+IgB GYbFDTyuN7IqVhKajgmN1rvyKCXbkaYpcOaMoFJ5fijMyAnaIkGBUSPZf1frTFyFcB 3uSs07ULOUMJB3lT+7HYpmJgCtIUTdsgsZ/KSyja/se9NvhQT1kx1ON/zhq7EflDm3 sBcyMFbw6X1YQHbeipvNKgujXefDZnpKxTyURCZLMkq8n5z9DfCz0jLIrV6WOEvEkn Ea3HPtQ0JRWAw== Message-ID: <98f19584-9851-46f0-a9dc-8dbae1793b72@kernel.org> Date: Mon, 27 May 2024 13:51:18 +0200 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH] w1: Fix number of bytes in error message To: Thorsten Blum Cc: linux-kernel@vger.kernel.org References: <20240513154354.185974-3-thorsten.blum@toblux.com> From: Krzysztof Kozlowski Content-Language: en-US Autocrypt: addr=krzk@kernel.org; keydata=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sBv0oDcsQWXqY+NaFahT0lRPjYtrTa1v3tem/ JoFzZ4B0p27K+qQCF2R96hVvuEyjzBmdq2esyE6zIqftdo4MOJho8uctOiWbwNNq2U9pPWmu 4vXVFBYIGmpyNPYzRm0QPwARAQABwsF8BBgBCgAmAhsMFiEEm9B+DgxR+NWWd7dUG5NDfTtB YpsFAmA872oFCRRflLYACgkQG5NDfTtBYpvScw/9GrqBrVLuJoJ52qBBKUBDo4E+5fU1bjt0 Gv0nh/hNJuecuRY6aemU6HOPNc2t8QHMSvwbSF+Vp9ZkOvrM36yUOufctoqON+wXrliEY0J4 ksR89ZILRRAold9Mh0YDqEJc1HmuxYLJ7lnbLYH1oui8bLbMBM8S2Uo9RKqV2GROLi44enVt vdrDvo+CxKj2K+d4cleCNiz5qbTxPUW/cgkwG0lJc4I4sso7l4XMDKn95c7JtNsuzqKvhEVS oic5by3fbUnuI0cemeizF4QdtX2uQxrP7RwHFBd+YUia7zCcz0//rv6FZmAxWZGy5arNl6Vm lQqNo7/Poh8WWfRS+xegBxc6hBXahpyUKphAKYkah+m+I0QToCfnGKnPqyYIMDEHCS/RfqA5 t8F+O56+oyLBAeWX7XcmyM6TGeVfb+OZVMJnZzK0s2VYAuI0Rl87FBFYgULdgqKV7R7WHzwD uZwJCLykjad45hsWcOGk3OcaAGQS6NDlfhM6O9aYNwGL6tGt/6BkRikNOs7VDEa4/HlbaSJo 7FgndGw1kWmkeL6oQh7wBvYll2buKod4qYntmNKEicoHGU+x91Gcan8mCoqhJkbqrL7+nXG2 5Q/GS5M9RFWS+nYyJh+c3OcfKqVcZQNANItt7+ULzdNJuhvTRRdC3g9hmCEuNSr+CLMdnRBY fv0= In-Reply-To: <20240513154354.185974-3-thorsten.blum@toblux.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit On 13/05/2024 17:43, Thorsten Blum wrote: > Fix the number of bytes that failed to be allocated for a new w1 device. > > Signed-off-by: Thorsten Blum > --- > drivers/w1/w1_int.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/w1/w1_int.c b/drivers/w1/w1_int.c > index 3a71c5eb2f83..677e7167806c 100644 > --- a/drivers/w1/w1_int.c > +++ b/drivers/w1/w1_int.c > @@ -34,7 +34,7 @@ static struct w1_master *w1_alloc_dev(u32 id, int slave_count, int slave_ttl, > dev = kzalloc(sizeof(struct w1_master) + sizeof(struct w1_bus_master), GFP_KERNEL); > if (!dev) { > pr_err("Failed to allocate %zd bytes for new w1 device.\n", > - sizeof(struct w1_master)); > + sizeof(struct w1_master) + sizeof(struct w1_bus_master)); No, instead error message should be dropped. Core handles printing memory allocation failures. Best regards, Krzysztof