From mboxrd@z Thu Jan 1 00:00:00 1970 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 C5DAE5676; Sat, 30 Dec 2023 11:34:51 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="U5n/1dIl" Received: by smtp.kernel.org (Postfix) with ESMTPSA id D72A9C433C8; Sat, 30 Dec 2023 11:34:47 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1703936091; bh=1yYEGXvx/YDRGmJ5mBECuPkbf2R58XFI65h+zZJ+hE8=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=U5n/1dIlvru2ILAHUy4fukwKHQtmfPKekQCobkHm8aCa74HOEwFVtKbfuKSg3xC8c ytDK4wl5vBK7RcWCnD5dmVoqMxb3KvJv2K3vyQCHniMBniHW17q9u2XE2nkwiNe88F hSjZdO7PG1Febjzvx4aHs3CNnbxJuG5FG+BmyOr42RkW4TFwEyjm49QlxWysEc05vb bNDLhA1vOWrC8D4CB2u33muSOLUT0hBvXy084NhfVKWo//DDq0aY+FyW4VgPmr9fyk eKR3nnNPMOyps0uRBKXtsvT/067UNJAWZdDFL7sg8+Z/f+M7gzRj18IdFBu5R72pYu jZnZDbZs70+zg== Date: Sat, 30 Dec 2023 11:34:44 +0000 From: Jonathan Cameron To: Andy Shevchenko Cc: Petre Rodan , linux-iio@vger.kernel.org, linux-kernel@vger.kernel.org, Andreas Klinger , Lars-Peter Clausen , Angel Iglesias , Matti Vaittinen Subject: Re: [PATCH v2 08/10] iio: pressure: mprls0025pa.c refactor Message-ID: <20231230113444.74de6b93@jic23-huawei> In-Reply-To: References: <20231224143500.10940-1-petre.rodan@subdimension.ro> <20231224143500.10940-9-petre.rodan@subdimension.ro> <20231226164922.6d7132c1@jic23-huawei> X-Mailer: Claws Mail 4.2.0 (GTK 3.24.38; x86_64-pc-linux-gnu) Precedence: bulk X-Mailing-List: linux-iio@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit On Wed, 27 Dec 2023 18:37:42 +0200 Andy Shevchenko wrote: > On Wed, Dec 27, 2023 at 04:33:37PM +0200, Petre Rodan wrote: > > On Tue, Dec 26, 2023 at 04:49:22PM +0000, Jonathan Cameron wrote: > > ,,, > > > > > ret = devm_request_irq(dev, data->irq, mpr_eoc_handler, > > > > - IRQF_TRIGGER_RISING, client->name, data); > > > > + IRQF_TRIGGER_RISING, dev_name(dev), data); > > > > > > Even though you'll change it again here, would have been nice to have > > > the alignment fixed in the earlier patch then the code update here. > > > > I tried this, but due to the fact that the line has to be right-aligned to > > column 80 we will still see a whitespace difference due to the length diff of > > the name-related argument. > > You can split in the previous patch accordingly, so data comes to a new line. > > ... > > > > > +#include > > > > > > Why include this? Can't see an IIO specific stuff in here. > > > > tried to remove it and > > > > CC [M] mprls0025pa_i2c.o > > mprls0025pa.h:89:63: error: 'IIO_DMA_MINALIGN' undeclared here (not in a function); did you mean 'ARCH_DMA_MINALIGN'? > > 89 | u8 buffer[MPR_MEASUREMENT_RD_SIZE] __aligned(IIO_DMA_MINALIGN); > > > I guess it makes more sense to move it to the .h file, where buffer[] is defined. > > Yes, C-code and especially headers should follow IWYI principle. The real user > of that definition is _the header_ file, and not C in this case. Absolutely - it is clear why this should be included from the header file. Jonathan > >