From patchwork Wed Jun 5 18:02:37 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Joy Chakraborty X-Patchwork-Id: 13687294 Received: from mail-yb1-f201.google.com (mail-yb1-f201.google.com [209.85.219.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 68ECD15381A for ; Wed, 5 Jun 2024 18:03:11 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.219.201 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1717610593; cv=none; b=IFC+hiKoLAvXeHpvg60OJVnqyipctVjiOLfZ83uvHlvGmetppY61ayqchE70eXiiMtRsC0PdgWl6YwbA6tzzLgg/o8Zc8Rf5LNvqB5u1/VyZFhau41fRuvs78G+ZKa1Ty/hjZfuqeRgFnfWMN9/SpKCkw+g6qhTVsegbjvdSBIg= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1717610593; c=relaxed/simple; bh=e26lRTuAGuJgmNX9Kn+IMmOklmBtw9bMfbnFAWkr9AI=; h=Date:In-Reply-To:Mime-Version:References:Message-ID:Subject:From: To:Cc:Content-Type; b=nel2HyZryX2pW7XoUAmJEtGeQjaH4qLzlcrPBs+6N1OY/64IAP04vV14/JMHv6Tz+esjDFHjAWZ5khRXsD0COSzW6OS7QQh9pYjAB3mqHo3DnHh5c4oSberHjC8qGDQtc1YrCekHQ2ku/fepa1m6lUJE9qeGBZ6fggLdSi4b/K4= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=google.com; spf=pass smtp.mailfrom=flex--joychakr.bounces.google.com; dkim=pass (2048-bit key) header.d=google.com header.i=@google.com header.b=XH5mJeVg; arc=none smtp.client-ip=209.85.219.201 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=google.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=flex--joychakr.bounces.google.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=google.com header.i=@google.com header.b="XH5mJeVg" Received: by mail-yb1-f201.google.com with SMTP id 3f1490d57ef6-df4d62ff39fso235817276.2 for ; Wed, 05 Jun 2024 11:03:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20230601; t=1717610590; x=1718215390; darn=vger.kernel.org; h=cc:to:from:subject:message-id:references:mime-version:in-reply-to :date:from:to:cc:subject:date:message-id:reply-to; bh=LqJdwI0kfu08l8zta4NZb2Dhq8rse0Xjye+A2f9mH7A=; b=XH5mJeVgmcHl8j+yAfDOF16fwTYZtKejt7N1AtlCr+jCLGqcaGoPbC1Z1OtBWbLeqR qu79bjTNXUQMB96hPCihyWcQ7C6/Xdw+CBz8yYYRpPef1O1wHiiuWHHNBbDn6basncKb feIXaxtnwyQFOXnN4GFHve22CLjHAlNw4tytPP/A1BS6KFsL/yDzrPALUUPMTBYiZfhz /ryZI+W919gn4EVH3x641KfCaNVJQjgsw4/EZWvrftTVoVBJm8vaVE+cvQcDoqWXj/KX CClLti2T1o6M0md9Eq1LS/CykQoF/EIHK2zXiNh5MwW8WJgwpltYQmZp/slPCc7x/UQZ lGeQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1717610590; x=1718215390; h=cc:to:from:subject:message-id:references:mime-version:in-reply-to :date:x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=LqJdwI0kfu08l8zta4NZb2Dhq8rse0Xjye+A2f9mH7A=; b=DMVD1kriOmM6FBGkiNrlvrJNT017NgRUmoRIEarqu4WU7gWUErZkcZHrBv47e592DF tUZwH2O1ufEUXMJSuwYOxKuh4eNkedD96vz+G5O3IF02E/Zb+3IkO9t5kcNRrKn7rTDF /PEUPyPvUHTAPzAVP8CPT9a2pQyrqTN2EOFTz5524cm7WKsJ6vp1um54bIAH5jhRQRwW x9L1XfOALndfbhVEjgnJrgzHHtjRXyAfpL5cxgwAXFOI/ide9kk2vJ4kckU759rqCrru iBbeBs0Kl5awNdx0GloJmckrZ74b3Us1qgrX+K1Rp5NxYkX2rOmMDmfNsfVcfSPtX0Ig oJ7w== X-Gm-Message-State: AOJu0YzONRUR9SySSOTaO5k1Lw2Z+YNUNJTKyyMrviAwTU3AUPymTxKO AkbygbgMX8AQYOoNXKTj7U5BSE0Kn5TlkTvisYi4JzGtEugnt2WpdOFDdXujXln6CHipOSL3u5j IFwSakhq2UQ== X-Google-Smtp-Source: AGHT+IFarMTHRQyaGAXOhvjvZC3Ev9S2zTS3Kvs5hpqZrMnxro2/BzrazXCSnRirdCi4qPaGa/c0QONTMKwCWA== X-Received: from joychakr.c.googlers.com ([fda3:e722:ac3:cc00:4f:4b78:c0a8:6ea]) (user=joychakr job=sendgmr) by 2002:a25:d608:0:b0:df7:d31b:7a29 with SMTP id 3f1490d57ef6-dfacad1dc1amr763889276.12.1717610590398; Wed, 05 Jun 2024 11:03:10 -0700 (PDT) Date: Wed, 5 Jun 2024 18:02:37 +0000 In-Reply-To: <20240605180238.2617808-1-joychakr@google.com> Precedence: bulk X-Mailing-List: linux-hwmon@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: Mime-Version: 1.0 References: <20240605180238.2617808-1-joychakr@google.com> X-Mailer: git-send-email 2.45.1.467.gbab1589fc0-goog Message-ID: <20240605180238.2617808-7-joychakr@google.com> Subject: [PATCH v1 16/17] soc: tegra: fuse: Change nvmem reg_read/write return type From: Joy Chakraborty To: Srinivas Kandagatla , Greg Kroah-Hartman , AngeloGioacchino Del Regno , Lars-Peter Clausen , Sakari Ailus , Bingbu Cao , Zhihao Cheng , Jerome Brunet , Martin Blumenstingl Cc: linux-hwmon@vger.kernel.org, linux-kernel@vger.kernel.org, linux-iio@vger.kernel.org, linux-media@vger.kernel.org, linux-i2c@vger.kernel.org, linux-gpio@vger.kernel.org, linux-mtd@lists.infradead.org, linux-rtc@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-amlogic@lists.infradead.org, linux-sunxi@lists.linux.dev, linux-tegra@vger.kernel.org, linux-usb@vger.kernel.org, manugautam@google.com, Joy Chakraborty Change nvmem read/write function definition return type to ssize_t. Signed-off-by: Joy Chakraborty --- drivers/soc/tegra/fuse/fuse-tegra.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/soc/tegra/fuse/fuse-tegra.c b/drivers/soc/tegra/fuse/fuse-tegra.c index b6bfd6729df3..1b067dd8a585 100644 --- a/drivers/soc/tegra/fuse/fuse-tegra.c +++ b/drivers/soc/tegra/fuse/fuse-tegra.c @@ -96,8 +96,8 @@ static const struct of_device_id tegra_fuse_match[] = { { /* sentinel */ } }; -static int tegra_fuse_read(void *priv, unsigned int offset, void *value, - size_t bytes) +static ssize_t tegra_fuse_read(void *priv, unsigned int offset, void *value, + size_t bytes) { unsigned int count = bytes / 4, i; struct tegra_fuse *fuse = priv; @@ -106,7 +106,7 @@ static int tegra_fuse_read(void *priv, unsigned int offset, void *value, for (i = 0; i < count; i++) buffer[i] = fuse->read(fuse, offset + i * 4); - return 0; + return bytes; } static void tegra_fuse_restore(void *base)