Devicetree
 help / color / mirror / Atom feed
From: Thomas Zimmermann <tzimmermann@suse.de>
To: Luca Weiss <luca.weiss@fairphone.com>,
	Neil Armstrong <neil.armstrong@linaro.org>,
	Jessica Zhang <jesszhan0024@gmail.com>,
	Maarten Lankhorst <maarten.lankhorst@linux.intel.com>,
	Maxime Ripard <mripard@kernel.org>,
	David Airlie <airlied@gmail.com>, Simona Vetter <simona@ffwll.ch>,
	Rob Herring <robh@kernel.org>,
	Krzysztof Kozlowski <krzk+dt@kernel.org>,
	Conor Dooley <conor+dt@kernel.org>,
	Bjorn Andersson <andersson@kernel.org>,
	Konrad Dybcio <konradybcio@kernel.org>
Cc: ~postmarketos/upstreaming@lists.sr.ht,
	phone-devel@vger.kernel.org, dri-devel@lists.freedesktop.org,
	devicetree@vger.kernel.org, linux-kernel@vger.kernel.org,
	linux-arm-msm@vger.kernel.org
Subject: Re: [PATCH 2/4] drm/panel: Add driver for Novatek NT37705 panel
Date: Fri, 15 May 2026 16:49:09 +0200	[thread overview]
Message-ID: <70130cc3-593e-4811-8c22-3e7b6fbe79ad@suse.de> (raw)
In-Reply-To: <DIJBW80W84I8.27QBZZD2BGAKO@fairphone.com>

Hi

Am 15.05.26 um 16:43 schrieb Luca Weiss:
[...]
> I checked and include/linux/container_of.h states:
>
>    Do not use container_of() in new code.
>
> and
>
>    Always prefer container_of_const() instead of container_of() in new code.
>
> So sounds like using container_of_const() is the correct way.

I didn't know that. Thanks!

Best regards
Thomas

>
>>>>> +
>>>>> +	ret = regulator_bulk_enable(ARRAY_SIZE(nt37705_supplies), ctx->supplies);
>>>>> +	if (ret < 0) {
>>>> Common style is to check for errors with
>>>>
>>>>      if (ret)
>>>>
>>>> Here and everywhere else.
>>> At least for regulator_bulk_enable() "ret < 0" is actually more popular
>>> than just "ret".
>>>
>>> Kernel doc says "Return: 0 on success or a negative error number on
>>> failure." so a positive integer should in theory never happen so they're
>>> equivalent.
>>>
>>> (git grep -h -A2 regulator_bulk_enable | grep if | sed 's|^[ \t]\+||' | sed 's| {$||' | sort | uniq -c)
>> It's just nitpicking, not a blocker.
> I was also curious so I dug around a bit :)
>
> Regards
> Luca

-- 
--
Thomas Zimmermann
Graphics Driver Developer
SUSE Software Solutions Germany GmbH
Frankenstr. 146, 90461 Nürnberg, Germany, www.suse.com
GF: Jochen Jaser, Andrew McDonald, Werner Knoblich, (HRB 36809, AG Nürnberg)



  reply	other threads:[~2026-05-15 14:49 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-05-01 13:52 [PATCH 0/4] Add Novatek NT37705 panel driver for Fairphone (Gen. 6) Luca Weiss
2026-05-01 13:52 ` [PATCH 1/4] dt-bindings: display: panel: Add Novatek NT37705 Luca Weiss
2026-05-01 15:51   ` Conor Dooley
2026-05-04 13:36     ` Luca Weiss
2026-05-04 20:45       ` Krzysztof Kozlowski
2026-05-04 20:47         ` Krzysztof Kozlowski
2026-05-05  6:40         ` Luca Weiss
2026-05-05  7:25           ` Krzysztof Kozlowski
2026-05-08  7:44             ` Luca Weiss
2026-05-14 15:11               ` Krzysztof Kozlowski
2026-05-14 15:12                 ` Krzysztof Kozlowski
2026-05-01 13:52 ` [PATCH 2/4] drm/panel: Add driver for Novatek NT37705 panel Luca Weiss
2026-05-01 18:17   ` David Heidelberg
2026-05-08  8:06   ` Thomas Zimmermann
2026-05-15 14:31     ` Luca Weiss
2026-05-15 14:36       ` Thomas Zimmermann
2026-05-15 14:43         ` Luca Weiss
2026-05-15 14:49           ` Thomas Zimmermann [this message]
2026-05-01 13:52 ` [PATCH 3/4] arm64: defconfig: Enable " Luca Weiss
2026-05-04 22:41   ` Dmitry Baryshkov
2026-05-01 13:52 ` [PATCH 4/4] arm64: dts: qcom: milos-fairphone-fp6: Enable display Luca Weiss
2026-05-04 22:40   ` Dmitry Baryshkov

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=70130cc3-593e-4811-8c22-3e7b6fbe79ad@suse.de \
    --to=tzimmermann@suse.de \
    --cc=airlied@gmail.com \
    --cc=andersson@kernel.org \
    --cc=conor+dt@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=jesszhan0024@gmail.com \
    --cc=konradybcio@kernel.org \
    --cc=krzk+dt@kernel.org \
    --cc=linux-arm-msm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=luca.weiss@fairphone.com \
    --cc=maarten.lankhorst@linux.intel.com \
    --cc=mripard@kernel.org \
    --cc=neil.armstrong@linaro.org \
    --cc=phone-devel@vger.kernel.org \
    --cc=robh@kernel.org \
    --cc=simona@ffwll.ch \
    --cc=~postmarketos/upstreaming@lists.sr.ht \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox