iio: humidity: hts221: Fix checkpatch blank line warning
Subsystems (2)
PATCH 1/1 iio: humidity: hts221: Fix checkpatch blank line warning
Checkpatch warning:
WARNING: Missing a blank line after declarations
+ struct hts221_hw *hw = iio_priv(iio_dev);
--- drivers/iio/humidity/hts221_buffer.c | 1 + 1 file changed, 1 insertion(+)
drivers/iio/humidity/hts221_buffer.c +1 -0
@@ -194,6 +194,7 @@ static irqreturn_t hts221_buffer_handler_thread(int irq, void *p)int hts221_allocate_buffers (struct iio_dev *iio_dev) {struct hts221_hw *hw =iio_priv (iio_dev); +return devm_iio_triggered_buffer_setup (hw->dev, iio_dev,NULL , hts221_buffer_handler_thread, &hts221_buffer_ops);
Signature · 1 line
2.47.3
Quoted 7 lines · On Sun, 2 Aug 2026 10:06:13 +0800 Adi Nata…
Checkpatch warning:
WARNING: Missing a blank line after declarations
(quoted diff) +1
-0+ struct hts221_hw *hw = iio_priv(iio_dev);Signed-off-by Adi Nata <[email protected]>---
This seems like churn on its own, Jonathan may not apply it.
Also, I feel like just putting checkpatch warnings directly into the commit message is bad practice. Much better if it were "Add a blank line after variable declarations per checkpatch warning."
Signature · 2 lines
Kind regards, Joshua Crofts
Jonathan Cameron
maintainerQuoted 5 lines · On Sun, 2 Aug 2026 17:38:52 +0200 Joshua Crofts <[email protected]>…
Quoted 2 lines · On Sun, 2 Aug 2026 10:06:13 +0800 Adi Nata…
Checkpatch warning:
Quoted 8 lines
Quoted 5 lines
WARNING: Missing a blank line after declarations
(quoted diff) +1
-0+ struct hts221_hw *hw = iio_priv(iio_dev);Signed-off-by Adi Nata <[email protected]>---
This seems like churn on its own, Jonathan may not apply it.
True. This highlights a broader point. When making
a number of cleanups to a driver (and I am generally more willing to take those than many maintainers) please group them into a little patch series with a cover letter.
If this is one of a set and overall the seem worthwhile I might pick them up. Plus this driver is pretty aged so there are other quality of code / modernization things that will make much more of an impact than just this blank line. Take a look at some of the other similar cleanup series on the IIO list and see what makes sense here. To give you a starter, dev_err_probe() and checking which prints are actually useful + stopping the driver rejecting Device tree falllback compatibles because of the hard fail on a device ID mismatch.
Quoted 4 lines
Also, I feel like just putting checkpatch warnings directly into the commit message is bad practice. Much better if it were "Add a blank line after variable declarations per checkpatch warning."
Fully agree with this. We really don't care what the print is, just what is being improved and why.
Thanks
Jonathan
Quoted 25 lines · Jonathan Cameron
On Sun, 2 Aug 2026 17:38:52 +0200
Joshua Crofts <[email protected]> wrote:True. This highlights a broader point. When making
a number of cleanups to a driver (and I am generally more willing to take those than many maintainers) please group them into a little patch series with a cover letter.If this is one of a set and overall the seem worthwhile I might pick them up. Plus this driver is pretty aged so there are other quality of code / modernization things that will make much more of an impact than just this blank line. Take a look at some of the other similar cleanup series on the IIO list and see what makes sense here. To give you a starter,
dev_err_probe()and checking which prints are actually useful + stopping the driver rejecting Device tree falllback compatibles because of the hard fail on a device ID mismatch.Quoted 4 lines
Also, I feel like just putting checkpatch warnings directly into the commit message is bad practice. Much better if it were "Add a blank line after variable declarations per checkpatch warning."
Quoted 7 lines
Fully agree with this. We really don't care what the print is, just what is being improved and why.
Thanks
Jonathan
Hi Jonathan and Joshua,
Thank you for the advice. I will create a new patch series with a cover letter for this hts221 driver accordingly based on your feedback.
Regards,
Adi Nata