From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-pj1-f46.google.com (mail-pj1-f46.google.com [209.85.216.46]) (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 740992C08DC for ; Wed, 13 May 2026 18:13:56 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.216.46 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1778696037; cv=none; b=HV0aR8zg7eQaZev/vO2388uBIEdGojWAeyQ9BpiJIRQoalPSsbI6/hznrZBwlzk0+02WIlgFwZxVVuUjhu66EfuIkHFrYIblX4Rq0V/RvCEkAU707JzgDPOKXBvOUJAX2hRcGq6VeAbX8Y/vguzPouP4526xN9gZKmCStdsT+cc= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1778696037; c=relaxed/simple; bh=ZFL+7Djcj0/DP230M4MM8TLXMhv1ojlFJLVRfsFJCjQ=; h=Mime-Version:Content-Type:Date:Message-Id:To:From:Subject:Cc: References:In-Reply-To; b=MBIgBgDhr9lOpxhHoRHa9fPnsdLxvq58qZAlawmQMzszv0SLAIFU0E+rtCaSPsreWChY6rw8xJwzNA2sxMH+Ol1arXl0hkxhKbMv9GzxCybgBmo8eVm4R9VXCvOt+79jikV+TjnoF2Ad1RyNz8cdHE6c8LJFb/5jaDBKv1T0GO0= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=eedpueA2; arc=none smtp.client-ip=209.85.216.46 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="eedpueA2" Received: by mail-pj1-f46.google.com with SMTP id 98e67ed59e1d1-368f25ff4c4so992156a91.2 for ; Wed, 13 May 2026 11:13:56 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20251104; t=1778696036; x=1779300836; darn=vger.kernel.org; h=in-reply-to:references:cc:subject:from:to:message-id:date :content-transfer-encoding:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=QDI47/lyDeh2jyjuo/TfFuD9uBo+IMd4UEtvl0ZGglY=; b=eedpueA2CWtWZMuxpJG0eksFio0ZJxvbHSFP3b1e359kf4OyomE6hx1QSPlgNCKdo3 yp85SlAHUhSM23t6itdgi9BdxnT8RBeVu8gArFR0aTXFs84RKuWHhgkhY2Qgr4ILVyMC YPiyWl6lNk9uS4vh0QNExu2U1cWNwZZoYCbiY/jdrqPWzoMLCdlK7OJqQUSbKdWYTc6M hesmwbSHC05d6RVjCkso+iP4uKStZmIuWGbPiGbdIBP1bIEj+S0nGvd1bDpcEuLeiMoK me0AMG1jQHARXRSg9uopfxUpi460E49il8K9qA+WAtPaWqroNSpqmRwzpdeziIEw2jKE 9EBg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1778696036; x=1779300836; h=in-reply-to:references:cc:subject:from:to:message-id:date :content-transfer-encoding:mime-version:x-gm-gg:x-gm-message-state :from:to:cc:subject:date:message-id:reply-to; bh=QDI47/lyDeh2jyjuo/TfFuD9uBo+IMd4UEtvl0ZGglY=; b=FUYSfXMW3h+4GYwiWwrzpfZfKivY3IJLucnThHSogoRU1RV1awSNer5A7Ek0dHISRP ZLH+kbAQFVNoJ+mKhXnXfXNopO38acvgnpgRcPmJ0o9aYpSm2vHmo7qKv146oX53alyk YvHG+G0B+F79wYmFoDD2ATeYRklNlwIDjQVNtA+fFoITrzIXejyMSQoXcO7x8C753A8k 07Y7U+uwLiPHuR7cuOIkZyfCsTdVDmVgmcakVq69BXjFrkoRJgGbzMK9i1kV4ck+DBCF Sk8cdBp2luL5Vap9PQLL7dv7MRTPFqZAuuPfVvXTcI867s7fzn1aL8utP9J/q4xxa6hT N9Mw== X-Forwarded-Encrypted: i=1; AFNElJ/8THBuiIX9khZZSLW9n5JrIN3ZUyQuj1xY+Io+xRLgkZmRHalSi5EpyUHzE+mUyTik7+rTKEpKodikShY=@vger.kernel.org X-Gm-Message-State: AOJu0YySV8633ujOAHwLMfqeRiKo1gmpHF2s56Daq8PErAXo+USA4pmW LdtaqKOLZFzDhlyygdgSIIAsWo+F24upTxCv9mymU0Py+8eWEemW3qgg X-Gm-Gg: Acq92OFmUl4xd7HmOgf7RUhoMGgBWn7d7Z2kdV/pOOqioz4AQez1zv6w3MCpGphCXJW 52NCs8h8weCa+SWhMhong47/kO/kpzyrBWQte2Iovb7/ryAn1/tQhUtJ0coMu/jVsslbiz53MxI gD6aBlbT7mMR9fHywSc3OllFTKWN4BaSADIC4Uu5zg8oUaLbKejXJS6SPeDhSil416PD9S4r2eV mUhSXAQnpak6w9THTOVy0yK/JPDkd0oB/krSK/tBN/koVCAXkvhssrO0RE/BZH++gM7lwkSRdpb T8p6dmEEJ2K4wce47nCDmOnbf4lJE9IKNLflj6JZ/sD3q0gP/e/vFHVykSyWjQOvkIOZt+azY9X q7FIWPvFz+N8S5h1viNh1xBmSJDvo76qD3LDKeBBmukHLa/NoIVSxIvoMkUeShLsiGOYvMYSu9W enEo72D+cTjjOpzlc07JUxDKoNeDHxpbYSag== X-Received: by 2002:a17:90b:28cf:b0:366:7dbd:cd50 with SMTP id 98e67ed59e1d1-368f40a3a66mr5027615a91.27.1778696035612; Wed, 13 May 2026 11:13:55 -0700 (PDT) Received: from localhost ([203.99.159.235]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-3692accfe37sm15072a91.14.2026.05.13.11.13.46 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Wed, 13 May 2026 11:13:55 -0700 (PDT) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: Mime-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=UTF-8 Date: Thu, 14 May 2026 07:13:41 +1300 Message-Id: To: "Andy Shevchenko" From: "Javier Carrasco" Subject: Re: [PATCH v2 2/4] iio: light: veml6030: fix channel type when pushing events Cc: "Jonathan Cameron" , "Lars-Peter Clausen" , "Rob Herring" , "Krzysztof Kozlowski" , "Conor Dooley" , "Rishi Gupta" , "David Lechner" , =?utf-8?q?Nuno_S=C3=A1?= , "Andy Shevchenko" , "Matti Vaittinen" , , , X-Mailer: aerc 0.20.1-4-g02324e9d9cab References: <20260513-veml6031x00-v2-0-4703ca661a1d@gmail.com> <20260513-veml6031x00-v2-2-4703ca661a1d@gmail.com> In-Reply-To: On Thu May 14, 2026 at 6:48 AM +13, Andy Shevchenko wrote: > On Wed, May 13, 2026 at 05:49:42PM +1300, Javier Carrasco wrote: >> The events are registered for IIO_LIGHT and not for IIO_INTENSITY. >> Use the correct channel type. > >> This bug was introduced in the first version of the driver. > > Unneeded detail, if it's a bug, use Fixes tag. > >> When at it, fix minor checkpatch code style warning (alignment). > > ... > >> - iio_push_event(indio_dev, IIO_UNMOD_EVENT_CODE(IIO_INTENSITY, >> - 0, IIO_EV_TYPE_THRESH, evtdir), >> - iio_get_time_ns(indio_dev)); >> + iio_push_event(indio_dev, IIO_UNMOD_EVENT_CODE(IIO_LIGHT, >> + 0, >> + IIO_EV_TYPE_THRESH, >> + evtdir), >> + iio_get_time_ns(indio_dev)); > > AFAICS the indentation is still broken. Why not doing like this: > > iio_push_event(indio_dev, > IIO_UNMOD_EVENT_CODE(IIO_LIGHT, 0, IIO_EV_TYPE_THRESH, evtdir), > iio_get_time_ns(indio_dev)); Hi Andy, Thank you for your feedback. According to checkpatch.pl, both variants are fine. Mine takes into account the indentation within IIO_UNMOD_EVENT_CODE(), and yours only accounts for the indentation for the arguments of iio_push_event(). Moreover, your suggestion goes beyond 80 characters and mine does not, so I would prefer sticking to mine if possible. As I said, it passes checkpatch --strict without warnings in both cases. I will send a new version adding the Fixes tag and removing the comment. Best regards, Javier