Re: [PATCH v17 0/9] Enable Adaptive Sync SDP Support for DP

2024-04-19 Thread Maxime Ripard
On Fri, Apr 19, 2024 at 05:09:29PM +0300, Jani Nikula wrote:
> On Fri, 19 Apr 2024, Maxime Ripard  wrote:
> > On Fri, Apr 19, 2024 at 03:35:55PM +0300, Jani Nikula wrote:
> >> On Thu, 04 Apr 2024, "Nautiyal, Ankit K"  
> >> wrote:
> >> > On 3/19/2024 3:16 PM, Maxime Ripard wrote:
> >> >> On Mon, Mar 18, 2024 at 04:37:58PM +0200, Jani Nikula wrote:
> >> >>> On Mon, 11 Mar 2024, Mitul Golani 
> >> >>>  wrote:
> >> >>>>   An Adaptive-Sync-capable DP protocol converter indicates its
> >> >>>> support by setting the related bit in the DPCD register. This
> >> >>>> is valid for DP and edp as well.
> >> >>>>
> >> >>>> Computes AS SDP values based on the display configuration,
> >> >>>> ensuring proper handling of Variable Refresh Rate (VRR)
> >> >>>> in the context of Adaptive Sync.
> >> >>> [snip]
> >> >>>
> >> >>>> Mitul Golani (9):
> >> >>>>drm/dp: Add support to indicate if sink supports AS SDP
> >> >>>>drm: Add Adaptive Sync SDP logging
> >> >>> Maarten, Maxime, Thomas, ack for merging these two patches via
> >> >>> drm-intel-next?
> >> >> Ack
> >> >>
> >> >> Maxime
> >> >
> >> > Thanks for the patch, ack and reviews, pushed to drm-intel-next.
> >> 
> >> This came up again today [1]. The acks absolutely must be recorded in
> >> the commit messages when pushing the patches.
> >> 
> >> dim should complain about applying non-i915 patches without acks.
> >
> > It doesn't at the moment, this has bitten us a couple of times in
> > drm-misc too.
> 
> See check_maintainer() that gets called from apply_patch() and
> dim_b4_shazam_branch().

Oh, right, I missed it sorry.

> It's of limited value, but it should complain while applying non-i915
> patches.
> 
> > I did a MR to address that that hasn't been reviewed yet:
> > https://gitlab.freedesktop.org/drm/maintainer-tools/-/merge_requests/40
> 
> Yeah, a more generic solution is needed, but I think we should unify
> with the above.

Fully agreed, I'll rework it.

Thanks!
Maxime


signature.asc
Description: PGP signature


Re: [PATCH v17 0/9] Enable Adaptive Sync SDP Support for DP

2024-04-19 Thread Maxime Ripard
On Fri, Apr 19, 2024 at 03:35:55PM +0300, Jani Nikula wrote:
> On Thu, 04 Apr 2024, "Nautiyal, Ankit K"  wrote:
> > On 3/19/2024 3:16 PM, Maxime Ripard wrote:
> >> On Mon, Mar 18, 2024 at 04:37:58PM +0200, Jani Nikula wrote:
> >>> On Mon, 11 Mar 2024, Mitul Golani  
> >>> wrote:
> >>>>   An Adaptive-Sync-capable DP protocol converter indicates its
> >>>> support by setting the related bit in the DPCD register. This
> >>>> is valid for DP and edp as well.
> >>>>
> >>>> Computes AS SDP values based on the display configuration,
> >>>> ensuring proper handling of Variable Refresh Rate (VRR)
> >>>> in the context of Adaptive Sync.
> >>> [snip]
> >>>
> >>>> Mitul Golani (9):
> >>>>drm/dp: Add support to indicate if sink supports AS SDP
> >>>>drm: Add Adaptive Sync SDP logging
> >>> Maarten, Maxime, Thomas, ack for merging these two patches via
> >>> drm-intel-next?
> >> Ack
> >>
> >> Maxime
> >
> > Thanks for the patch, ack and reviews, pushed to drm-intel-next.
> 
> This came up again today [1]. The acks absolutely must be recorded in
> the commit messages when pushing the patches.
> 
> dim should complain about applying non-i915 patches without acks.

It doesn't at the moment, this has bitten us a couple of times in
drm-misc too.

I did a MR to address that that hasn't been reviewed yet:
https://gitlab.freedesktop.org/drm/maintainer-tools/-/merge_requests/40

Maxime


signature.asc
Description: PGP signature


Re: [PULL] drm-intel-next

2024-04-19 Thread Maxime Ripard
Hi,

On Wed, Apr 17, 2024 at 09:38:55AM -0400, Rodrigo Vivi wrote:
> Another thing that it is important to highlight is that we have 3 drm level
> patches in this pull request where I didn't see any explicit recorded
> ack from you (drm maintainers) nor from drm-misc maintainers.
> The patches looks good to me and shouldn't cause conflict, so I hope it
> is okay to continue with them here instead of a big removal at this
> point.

Sigh...

I guess it's a good occasion to test
https://gitlab.freedesktop.org/drm/maintainer-tools/-/merge_requests/40

And merge it if it works.

Maxime


signature.asc
Description: PGP signature


Re: Re: [PATCH 1/2] drm/print: drop include debugfs.h and include where needed

2024-04-15 Thread Maxime Ripard
On Mon, 15 Apr 2024 16:09:22 +0300, Jani Nikula wrote:
> On Wed, 10 Apr 2024, Jani Nikula  wrote:
> > Surprisingly many places depend on debugfs.h to be included via
> > drm_print.h. Fix them.
> 
> While all of this is trivial, merely adding some includes, please
> 
> [ ... ]

Acked-by: Maxime Ripard 

Thanks!
Maxime


Re: [RESEND v3 2/2] drm: Add CONFIG_DRM_WERROR

2024-03-27 Thread Maxime Ripard
Hi,

On Tue, Mar 26, 2024 at 03:56:50PM -0700, Nathan Chancellor wrote:
> On Tue, Mar 05, 2024 at 11:07:36AM +0200, Jani Nikula wrote:
> > Add kconfig to enable -Werror subsystem wide. This is useful for
> > development and CI to keep the subsystem warning free, while avoiding
> > issues outside of the subsystem that kernel wide CONFIG_WERROR=y might
> > hit.
> > 
> > v2: Don't depend on COMPILE_TEST
> > 
> > Reviewed-by: Hamza Mahfooz  # v1
> > Signed-off-by: Jani Nikula 
> > ---
> >  drivers/gpu/drm/Kconfig  | 13 +
> >  drivers/gpu/drm/Makefile |  3 +++
> >  2 files changed, 16 insertions(+)
> > 
> > diff --git a/drivers/gpu/drm/Kconfig b/drivers/gpu/drm/Kconfig
> > index 6e853acf15da..c08e18108c2a 100644
> > --- a/drivers/gpu/drm/Kconfig
> > +++ b/drivers/gpu/drm/Kconfig
> > @@ -416,3 +416,16 @@ config DRM_LIB_RANDOM
> >  config DRM_PRIVACY_SCREEN
> > bool
> > default n
> > +
> > +config DRM_WERROR
> > +   bool "Compile the drm subsystem with warnings as errors"
> > +   depends on EXPERT
> > +   default n
> > +   help
> > + A kernel build should not cause any compiler warnings, and this
> > + enables the '-Werror' flag to enforce that rule in the drm subsystem.
> > +
> > + The drm subsystem enables more warnings than the kernel default, so
> > + this config option is disabled by default.
> > +
> > + If in doubt, say N.
> 
> While I understand the desire for an easy switch that maintainers and
> developers can use to ensure that their changes are warning free for the
> drm subsystem specifically, I think subsystem specific configuration
> options like this are actively detrimental to developers and continuous
> integration systems that build test the entire kernel. For example, we
> turned off CONFIG_WERROR for our Hexagon builds because of warnings that
> appear with -Wextra that are legitimate but require treewide changes to
> resolve in a manner sufficient for Linus:
> 
> https://github.com/ClangBuiltLinux/linux/issues/1285
> https://lore.kernel.org/all/CAHk-=wg80je=k7madf4e7wrrnp37e3qh6y10svhdc7o8sz_...@mail.gmail.com/
> https://lore.kernel.org/all/20230522105049.1467313-1-schne...@linux.ibm.com/
> 
> But now, due to CONFIG_DRM_WERROR getting enabled by all{mod,yes}config
> and -Wextra being unconditionally enabled for DRM, those warnings hard
> break the build despite CONFIG_WERROR=n...

Would making DRM_WERROR depends on WERROR address your concerns?

Maxime


signature.asc
Description: PGP signature


Re: [RESEND v3 1/6] drm/mst: read sideband messaging cap

2024-03-19 Thread Maxime Ripard
On Tue, Mar 19, 2024 at 11:20:16AM +0200, Jani Nikula wrote:
> On Tue, 19 Mar 2024, Jani Nikula  wrote:
> > Amend drm_dp_read_mst_cap() to return an enum, indicating "SST", "SST
> > with sideband messaging", or "MST". Modify all call sites to take the
> > new return value into account.
> 
> drm-misc and nouveau maintainers, ack for merging this via drm-intel,
> please?

Ack

Maxime


signature.asc
Description: PGP signature


Re: [PATCH v17 0/9] Enable Adaptive Sync SDP Support for DP

2024-03-19 Thread Maxime Ripard
On Mon, Mar 18, 2024 at 04:37:58PM +0200, Jani Nikula wrote:
> On Mon, 11 Mar 2024, Mitul Golani  
> wrote:
> >  An Adaptive-Sync-capable DP protocol converter indicates its
> > support by setting the related bit in the DPCD register. This
> > is valid for DP and edp as well.
> >
> > Computes AS SDP values based on the display configuration,
> > ensuring proper handling of Variable Refresh Rate (VRR)
> > in the context of Adaptive Sync.
> 
> [snip]
> 
> > Mitul Golani (9):
> >   drm/dp: Add support to indicate if sink supports AS SDP
> >   drm: Add Adaptive Sync SDP logging
> 
> Maarten, Maxime, Thomas, ack for merging these two patches via
> drm-intel-next?

Ack

Maxime


signature.asc
Description: PGP signature


Re: [PATCH 6/8] drm/vc4: hdmi: do not return negative values from .get_modes()

2024-03-08 Thread Maxime Ripard
On Fri, 8 Mar 2024 18:03:44 +0200, Jani Nikula wrote:
> The .get_modes() hooks aren't supposed to return negative error
> codes. Return 0 for no modes, whatever the reason.
> 
> Cc: Maxime Ripard 
> Cc: sta...@vger.kernel.org
> 
> [ ... ]

Acked-by: Maxime Ripard 

Thanks!
Maxime


[PULL] drm-misc-fixes

2024-03-07 Thread Maxime Ripard
Hi,

Here's this week drm-misc-fixes PR

Maxime

drm-misc-fixes-2024-03-07:
A connector status polling fix, a timings fix for the Himax83102-j02
panel, a deadlock fix for nouveau, A controversial format fix for udl
that got reverted to allow further discussion, and a build fix for the
drm/buddy kunit tests.
The following changes since commit c70703320e557ff30847915e6a7631a9abdda16b:

  drm/tests/drm_buddy: add alloc_range_bias test (2024-02-28 08:03:29 +0100)

are available in the Git repository at:

  https://anongit.freedesktop.org/git/drm/drm-misc 
tags/drm-misc-fixes-2024-03-07

for you to fetch changes up to 4ece8fc439c370b1aec26a44b9f94fb214068d42:

  drm/tests/buddy: fix print format (2024-03-07 09:28:06 +0100)


A connector status polling fix, a timings fix for the Himax83102-j02
panel, a deadlock fix for nouveau, A controversial format fix for udl
that got reverted to allow further discussion, and a build fix for the
drm/buddy kunit tests.


Cong Yang (1):
  drm/panel: boe-tv101wum-nl6: Fine tune Himax83102-j02 panel HFP and HBP 
(again)

Douglas Anderson (2):
  drm/udl: Add ARGB as a format
  Revert "drm/udl: Add ARGB as a format"

Imre Deak (1):
  drm: Fix output poll work for drm_kms_helper_poll=n

Karol Herbst (1):
  drm/nouveau: fix stale locked mutex in nouveau_gem_ioctl_pushbuf

Matthew Auld (1):
  drm/tests/buddy: fix print format

 drivers/gpu/drm/drm_probe_helper.c | 8 +---
 drivers/gpu/drm/nouveau/nouveau_gem.c  | 2 +-
 drivers/gpu/drm/panel/panel-boe-tv101wum-nl6.c | 8 
 drivers/gpu/drm/tests/drm_buddy_test.c | 2 +-
 4 files changed, 11 insertions(+), 9 deletions(-)


signature.asc
Description: PGP signature


Re: [PULL] drm-misc-fixes

2024-03-06 Thread Maxime Ripard
Hi,

On Thu, Feb 29, 2024 at 01:54:30PM +, Matthew Auld wrote:
> On 29/02/2024 13:37, Maxime Ripard wrote:
> > Hi,
> > 
> > Here's this week drm-misc fixes PR.
> > 
> > There's two commits for files unders drivers/soc/qcom that don't have a
> > maintainer Acked-by. Bjorn's Acked-by was provided on IRC, and Konrad
> > provided it by mail after the facts so we're covered.
> > 
> > Maxime
> > 
> > drm-misc-fixes-2024-02-29:
> > A reset fix for host1x, a resource leak fix and a probe fix for aux-hpd,
> > a use-after-free fix and a boot fix for a pmic_glink qcom driver in
> > drivers/soc, a fix for the simpledrm/tegra transition, a kunit fix for
> > the TTM tests, a font handling fix for fbcon, two allocation fixes and a
> > kunit test to cover them for drm/buddy
> > The following changes since commit 72fa02fdf83306c52bc1eede28359e3fa32a151a:
> > 
> >nouveau: add an ioctl to report vram usage (2024-02-23 10:20:07 +1000)
> > 
> > are available in the Git repository at:
> > 
> >https://anongit.freedesktop.org/git/drm/drm-misc 
> > tags/drm-misc-fixes-2024-02-29
> > 
> > for you to fetch changes up to c70703320e557ff30847915e6a7631a9abdda16b:
> > 
> >drm/tests/drm_buddy: add alloc_range_bias test (2024-02-28 08:03:29 
> > +0100)
> > 
> > 
> > A reset fix for host1x, a resource leak fix and a probe fix for aux-hpd,
> > a use-after-free fix and a boot fix for a pmic_glink qcom driver in
> > drivers/soc, a fix for the simpledrm/tegra transition, a kunit fix for
> > the TTM tests, a font handling fix for fbcon, two allocation fixes and a
> > kunit test to cover them for drm/buddy
> > 
> > 
> > Christian König (1):
> >drm/ttm/tests: depend on UML || COMPILE_TEST
> > 
> > Jiri Slaby (SUSE) (1):
> >fbcon: always restore the old font data in fbcon_do_set_font()
> > 
> > Johan Hovold (3):
> >drm/bridge: aux-hpd: fix OF node leaks
> >drm/bridge: aux-hpd: separate allocation and registration
> >soc: qcom: pmic_glink_altmode: fix drm bridge use-after-free
> > 
> > Matthew Auld (3):
> >drm/buddy: fix range bias
> >drm/buddy: check range allocation matches alignment
> >drm/tests/drm_buddy: add alloc_range_bias test
> 
> Note that there is a build fix needed for this one:
> https://patchwork.freedesktop.org/patch/580568/?series=130552=1

It looks like that patch still hasn't been applied. What's going on?

Maxime


signature.asc
Description: PGP signature


drm-tip Migration to Gitlab

2024-03-05 Thread Maxime Ripard
Hi,

In order to prepare for the drm-misc migration that should happen next
week, Benjamin and I just migrated drm-tip to Gitlab.

It should be effective as of 5 minutes ago, the old cgit repo being
currently marked read-only, and will be setup as a mirror.

Thanks to the work done last week, we should be able to smoothly
transition any dim user after running dim ub twice.

However, this is the first time we're migrating a repository that users
write to, so it might cause some issues for people that haven't setup
their Gitlab account, and especially their SSH key.

If that's the case, you should add your SSH key in Gitlab. See the
documentation here:
https://docs.gitlab.com/ee/user/ssh.html#add-an-ssh-key-to-your-gitlab-account

If it still doesn't work, please reach out to me.

Maxime


signature.asc
Description: PGP signature


Re: [RESEND v3 0/2] drm: enable W=1 warnings by default across the subsystem

2024-03-05 Thread Maxime Ripard
On Tue, 5 Mar 2024 11:07:34 +0200, Jani Nikula wrote:
> Resend of [1] with an intent to merge after the CI results come in. This
> is aiming for v6.10, so we'll have maximal time to find all the issues
> my configs didn't catch.
> 
> I built this on x86-64 (both gcc and clang), arm and arm64, and
> 
> [ ... ]

Acked-by: Maxime Ripard 

Thanks!
Maxime


[PULL] drm-misc-fixes

2024-02-29 Thread Maxime Ripard
Hi,

Here's this week drm-misc fixes PR.

There's two commits for files unders drivers/soc/qcom that don't have a
maintainer Acked-by. Bjorn's Acked-by was provided on IRC, and Konrad
provided it by mail after the facts so we're covered.

Maxime

drm-misc-fixes-2024-02-29:
A reset fix for host1x, a resource leak fix and a probe fix for aux-hpd,
a use-after-free fix and a boot fix for a pmic_glink qcom driver in
drivers/soc, a fix for the simpledrm/tegra transition, a kunit fix for
the TTM tests, a font handling fix for fbcon, two allocation fixes and a
kunit test to cover them for drm/buddy
The following changes since commit 72fa02fdf83306c52bc1eede28359e3fa32a151a:

  nouveau: add an ioctl to report vram usage (2024-02-23 10:20:07 +1000)

are available in the Git repository at:

  https://anongit.freedesktop.org/git/drm/drm-misc 
tags/drm-misc-fixes-2024-02-29

for you to fetch changes up to c70703320e557ff30847915e6a7631a9abdda16b:

  drm/tests/drm_buddy: add alloc_range_bias test (2024-02-28 08:03:29 +0100)


A reset fix for host1x, a resource leak fix and a probe fix for aux-hpd,
a use-after-free fix and a boot fix for a pmic_glink qcom driver in
drivers/soc, a fix for the simpledrm/tegra transition, a kunit fix for
the TTM tests, a font handling fix for fbcon, two allocation fixes and a
kunit test to cover them for drm/buddy


Christian König (1):
  drm/ttm/tests: depend on UML || COMPILE_TEST

Jiri Slaby (SUSE) (1):
  fbcon: always restore the old font data in fbcon_do_set_font()

Johan Hovold (3):
  drm/bridge: aux-hpd: fix OF node leaks
  drm/bridge: aux-hpd: separate allocation and registration
  soc: qcom: pmic_glink_altmode: fix drm bridge use-after-free

Matthew Auld (3):
  drm/buddy: fix range bias
  drm/buddy: check range allocation matches alignment
  drm/tests/drm_buddy: add alloc_range_bias test

Maxime Ripard (1):
  Merge drm/drm-fixes into drm-misc-fixes

Mikko Perttunen (1):
  gpu: host1x: Skip reset assert on Tegra186

Rob Clark (1):
  soc: qcom: pmic_glink: Fix boot when QRTR=m

Thierry Reding (1):
  drm/tegra: Remove existing framebuffer only if we support display

 drivers/gpu/drm/Kconfig |   5 +-
 drivers/gpu/drm/bridge/aux-hpd-bridge.c |  70 +++---
 drivers/gpu/drm/drm_buddy.c |  16 ++-
 drivers/gpu/drm/tegra/drm.c |  23 +++-
 drivers/gpu/drm/tests/drm_buddy_test.c  | 218 
 drivers/gpu/host1x/dev.c|  15 ++-
 drivers/gpu/host1x/dev.h|   6 +
 drivers/soc/qcom/pmic_glink.c   |  21 +--
 drivers/soc/qcom/pmic_glink_altmode.c   |  16 ++-
 drivers/video/fbdev/core/fbcon.c|   8 +-
 include/drm/bridge/aux-bridge.h |  15 +++
 11 files changed, 368 insertions(+), 45 deletions(-)


signature.asc
Description: PGP signature


Re: DRM Migration to Gitlab

2024-02-27 Thread Maxime Ripard
On Tue, Feb 27, 2024 at 10:18:01AM +0100, Maxime Ripard wrote:
> Hi Jani,
> 
> On Tue, Feb 27, 2024 at 10:29:01AM +0200, Jani Nikula wrote:
> > On Tue, 27 Feb 2024, Maxime Ripard  wrote:
> > > Hi,
> > >
> > > Sima, after becoming aware of the drm-misc transition to Gitlab in the
> > > next couple of weeks, to do the same for DRM today.
> > >
> > > This is now done and all the various bits (nightly.conf, MAINTAINERS,
> > > doc, etc.) should be there.
> > >
> > > If all goes well, the only thing you'll notice is that dim will complain
> > > about the drm remote not having the right URLs.
> > >
> > > Any dim user should update the URL with either one of the two following
> > > commands:
> > >
> > > git remote set-url drm ssh://g...@gitlab.freedesktop.org/drm/kernel.git
> > > git remote set-url drm https://gitlab.freedesktop.org/drm/kernel.git
> > >
> > > And the rest should be transparent.
> > 
> > Except it isn't. If you do that before updating to new nightly.conf,
> > it'll complain that the URL it sees in the old config isn't available,
> > and prompts.
> > 
> > If you first do 'dim ub', and then do 'dim ub' again, before changing
> > the URL, it'll also prompt, but it's unable to override the existing drm
> > remote.
> 
> Urgh, you're right... It's also partly due to drm-tip being the last
> repo to be updated. I've overlooked that aspect since I had the local
> changes to nightly.conf.
> 
> > I think dim should be updated to handle all of this without user
> > manually doing anything other than answering a yes/no prompt.
> 
> I've started to work on that, but it's probably going to take a bit of
> time to figure it out, bash isn't really my strong suit.

I've sent a MR to handle this:

https://gitlab.freedesktop.org/drm/maintainer-tools/-/merge_requests/39

Maxime


signature.asc
Description: PGP signature


Re: DRM Migration to Gitlab

2024-02-27 Thread Maxime Ripard
Hi Jani,

On Tue, Feb 27, 2024 at 10:29:01AM +0200, Jani Nikula wrote:
> On Tue, 27 Feb 2024, Maxime Ripard  wrote:
> > Hi,
> >
> > Sima, after becoming aware of the drm-misc transition to Gitlab in the
> > next couple of weeks, to do the same for DRM today.
> >
> > This is now done and all the various bits (nightly.conf, MAINTAINERS,
> > doc, etc.) should be there.
> >
> > If all goes well, the only thing you'll notice is that dim will complain
> > about the drm remote not having the right URLs.
> >
> > Any dim user should update the URL with either one of the two following
> > commands:
> >
> > git remote set-url drm ssh://g...@gitlab.freedesktop.org/drm/kernel.git
> > git remote set-url drm https://gitlab.freedesktop.org/drm/kernel.git
> >
> > And the rest should be transparent.
> 
> Except it isn't. If you do that before updating to new nightly.conf,
> it'll complain that the URL it sees in the old config isn't available,
> and prompts.
> 
> If you first do 'dim ub', and then do 'dim ub' again, before changing
> the URL, it'll also prompt, but it's unable to override the existing drm
> remote.

Urgh, you're right... It's also partly due to drm-tip being the last
repo to be updated. I've overlooked that aspect since I had the local
changes to nightly.conf.

> I think dim should be updated to handle all of this without user
> manually doing anything other than answering a yes/no prompt.

I've started to work on that, but it's probably going to take a bit of
time to figure it out, bash isn't really my strong suit.

If anyone is stuck with this, you can get unstuck manually by doing:

cd $DIM_PREFIX/drm-rerere
git checkout rerere-cache
git pull

cd $DIM_PREFIX/kernel
git remote set-url drm ...

There's been reports in private that some didn't get their branch
updated for some time and will have to add the drm/xe repo too:

git remote add drm-xe ssh://g...@gitlab.freedesktop.org/drm/xe/kernel.git

Maxime


signature.asc
Description: PGP signature


Re: [PATCH v2 00/21] drm/i915: Add Display Port tunnel BW allocation support

2024-02-26 Thread Maxime Ripard
On Mon, Feb 26, 2024 at 03:54:19PM +0200, Jani Nikula wrote:
> On Tue, 20 Feb 2024, Imre Deak  wrote:
> > This is v2 of [1], with the following changes:
> >
> > - Several functional/typo/formatting fixes, detailed in the patches.
> > - Move the BW allocation from encoder hooks to
> >   intel_atomic_commit_tail() fixing the allocation for MST streams
> >   enabled/disabled w/o a full modeset (i.e. w/o re-enabling the master
> >   stream).
> > - Fix an MST mode restore issue during system resume, which also lead
> >   to a tunnel BW allocation failure. (Patch 3)
> > - Ensure a DPCD DPRX cap read as required by the TBT CM any time a long
> >   HPD pulse is detected. (Patch 20)
> > - Explicitly disable the BW allocation mode during system suspend.
> >
> > The patchset is also available at:
> > https://github.com/ideak/linux/commits/dp_tun_bw_alloc
> >
> > Cc: Mika Westerberg 
> > Cc: Ville Syrjälä 
> > Cc: Uma Shankar 
> > Cc: Jouni Högander 
> > Cc: Saranya Gopal 
> > Cc: Rajaram Regupathy 
> > Cc: Gil Fine 
> > Cc: Naama Shachar 
> > Cc: Pengfei Xu 
> >
> > [1] https://lore.kernel.org/all/20240123102850.390126-1-imre.d...@intel.com
> >
> > Imre Deak (21):
> >   drm/dp: Add drm_dp_max_dprx_data_rate()
> >   drm/dp: Add support for DP tunneling
> 
> Maarten, Maxime, Thomas -
> 
> Ack for merging these two patches via drm-intel-next?

Yep, go ahead

Maxime


signature.asc
Description: PGP signature


Re: [PATCH] drm/i915: Fix possible null pointer dereference after drm_dbg_printer conversion

2024-02-22 Thread Maxime Ripard
On Mon, 19 Feb 2024 13:14:23 +, Tvrtko Ursulin wrote:
> Request can be NULL if no guilty request was identified so simply use
> engine->i915 instead.
> 
> 

Applied to drm/drm-misc (drm-misc-next-fixes).

Thanks!
Maxime


[PULL] drm-misc-fixes

2024-02-22 Thread Maxime Ripard
Hi,

Here's this week drm-misc-fixes PR

Maxime

drm-misc-fixes-2024-02-22:
A list handling fix and 64bit division on 32bit platform fix for the
drm/buddy allocator, a cast warning and an initialization fix for
nouveau, a bridge handling fix for meson, an initialisation fix for
ivpu, a SPARC build fix for fbdev, a double-free fix for ttm, and two
fence handling fixes for syncobj.
The following changes since commit a64056bb5a3215bd31c8ce17d609ba0f4d5c55ea:

  drm/tests/drm_buddy: add alloc_contiguous test (2024-02-14 15:22:21 +0100)

are available in the Git repository at:

  git://anongit.freedesktop.org/drm/drm-misc tags/drm-misc-fixes-2024-02-22

for you to fetch changes up to 2aa6f5b0fd052e363bb9d4b547189f0bf6b3d6d3:

  drm/syncobj: handle NULL fence in syncobj_eventfd_entry_func (2024-02-22 
13:52:52 +0100)


A list handling fix and 64bit division on 32bit platform fix for the
drm/buddy allocator, a cast warning and an initialization fix for
nouveau, a bridge handling fix for meson, an initialisation fix for
ivpu, a SPARC build fix for fbdev, a double-free fix for ttm, and two
fence handling fixes for syncobj.


Andrzej Kacprowski (1):
  accel/ivpu: Don't enable any tiles by default on VPU40xx

Arnd Bergmann (1):
  nouveau: fix function cast warnings

Arunpravin Paneer Selvam (1):
  drm/buddy: Modify duplicate list_splice_tail call

Dan Carpenter (1):
  drm/nouveau/mmu/r535: uninitialized variable in r535_bar_new_()

Erik Kurzinger (2):
  drm/syncobj: call drm_syncobj_fence_add_wait when WAIT_AVAILABLE flag is 
set
  drm/syncobj: handle NULL fence in syncobj_eventfd_entry_func

Javier Martinez Canillas (1):
  sparc: Fix undefined reference to fb_is_primary_device

Martin Blumenstingl (1):
  drm/meson: Don't remove bridges which are created by other drivers

Matthew Auld (1):
  drm/tests/drm_buddy: fix 32b build

Thomas Hellström (1):
  drm/ttm: Fix an invalid freeing on already freed page in error path

 arch/sparc/Makefile   |  2 +-
 arch/sparc/video/Makefile |  2 +-
 drivers/accel/ivpu/ivpu_hw_40xx.c |  2 +-
 drivers/gpu/drm/drm_buddy.c   |  4 ++--
 drivers/gpu/drm/drm_syncobj.c | 19 ---
 drivers/gpu/drm/meson/meson_encoder_cvbs.c|  1 -
 drivers/gpu/drm/meson/meson_encoder_dsi.c |  1 -
 drivers/gpu/drm/meson/meson_encoder_hdmi.c|  1 -
 drivers/gpu/drm/nouveau/nvkm/subdev/bar/r535.c|  5 ++---
 drivers/gpu/drm/nouveau/nvkm/subdev/bios/shadow.c |  8 +++-
 drivers/gpu/drm/tests/drm_buddy_test.c| 16 
 drivers/gpu/drm/ttm/ttm_pool.c|  2 +-
 12 files changed, 39 insertions(+), 24 deletions(-)


signature.asc
Description: PGP signature


Re: linux-next: build failure after merge of the drm-misc tree

2024-02-22 Thread Maxime Ripard
Hi Biju,

On Thu, Feb 22, 2024 at 08:14:14AM +, Biju Das wrote:
> > -Original Message-
> > From: Stephen Rothwell 
> > Sent: Thursday, February 22, 2024 1:46 AM
> > Subject: linux-next: build failure after merge of the drm-misc tree
> > 
> > Hi all,
> > 
> > After merging the drm-misc tree, today's linux-next build (x86_64
> > allmodconfig) failed like this:
> > 
> > drivers/gpu/drm/renesas/rz-du/rzg2l_du_vsp.c:47:6: error: redefinition of
> > 'rzg2l_du_vsp_enable'
> >47 | void rzg2l_du_vsp_enable(struct rzg2l_du_crtc *crtc)
> >   |  ^~~
> > In file included from drivers/gpu/drm/renesas/rz-du/rzg2l_du_drv.h:18,
> >  from drivers/gpu/drm/renesas/rz-du/rzg2l_du_vsp.c:30:
> > drivers/gpu/drm/renesas/rz-du/rzg2l_du_vsp.h:72:20: note: previous
> > definition of 'rzg2l_du_vsp_enable' with type 'void(struct rzg2l_du_crtc
> > *)'
> >72 | static inline void rzg2l_du_vsp_enable(struct rzg2l_du_crtc *crtc)
> > { };
> >   |^~~
> > drivers/gpu/drm/renesas/rz-du/rzg2l_du_vsp.c:61:6: error: redefinition of
> > 'rzg2l_du_vsp_disable'
> >61 | void rzg2l_du_vsp_disable(struct rzg2l_du_crtc *crtc)
> >   |  ^~~~
> > drivers/gpu/drm/renesas/rz-du/rzg2l_du_vsp.h:73:20: note: previous
> > definition of 'rzg2l_du_vsp_disable' with type 'void(struct rzg2l_du_crtc
> > *)'
> >73 | static inline void rzg2l_du_vsp_disable(struct rzg2l_du_crtc
> > *crtc) { };
> >   |^~~~
> > drivers/gpu/drm/renesas/rz-du/rzg2l_du_vsp.c:66:6: error: redefinition of
> > 'rzg2l_du_vsp_atomic_flush'
> >66 | void rzg2l_du_vsp_atomic_flush(struct rzg2l_du_crtc *crtc)
> >   |  ^
> > drivers/gpu/drm/renesas/rz-du/rzg2l_du_vsp.h:74:20: note: previous
> > definition of 'rzg2l_du_vsp_atomic_flush' with type 'void(struct
> > rzg2l_du_crtc *)'
> >74 | static inline void rzg2l_du_vsp_atomic_flush(struct rzg2l_du_crtc
> > *crtc) { };
> >   |^
> > drivers/gpu/drm/renesas/rz-du/rzg2l_du_vsp.c:76:19: error: redefinition of
> > 'rzg2l_du_vsp_get_drm_plane'
> >76 | struct drm_plane *rzg2l_du_vsp_get_drm_plane(struct rzg2l_du_crtc
> > *crtc,
> >   |   ^~
> > drivers/gpu/drm/renesas/rz-du/rzg2l_du_vsp.h:75:33: note: previous
> > definition of 'rzg2l_du_vsp_get_drm_plane' with type 'struct drm_plane
> > *(struct rzg2l_du_crtc *, unsigned int)'
> >75 | static inline struct drm_plane *rzg2l_du_vsp_get_drm_plane(struct
> > rzg2l_du_crtc *crtc,
> >   | ^~
> > drivers/gpu/drm/renesas/rz-du/rzg2l_du_vsp.c:302:5: error: redefinition of
> > 'rzg2l_du_vsp_init'
> >   302 | int rzg2l_du_vsp_init(struct rzg2l_du_vsp *vsp, struct device_node
> > *np,
> >   | ^
> > drivers/gpu/drm/renesas/rz-du/rzg2l_du_vsp.h:66:19: note: previous
> > definition of 'rzg2l_du_vsp_init' with type 'int(struct rzg2l_du_vsp *,
> > struct device_node *, unsigned int)'
> >66 | static inline int rzg2l_du_vsp_init(struct rzg2l_du_vsp *vsp,
> > struct device_node *np,
> >   |   ^
> > 
> > Caused by commit
> > 
> >   768e9e61b3b9 ("drm: renesas: Add RZ/G2L DU Support")
> > 
> > I have used the drm-misc tree from next-20240221 for today.
> 
> I will send an incremental patch to fix this build error with x86 on drm-next.

Any chance you can do it today? We need to send the drm-misc-next PR.

Maxime


signature.asc
Description: PGP signature


[PATCH] drm/i915/tv: Fix TV mode

2024-02-20 Thread Maxime Ripard
Commit 1fd4a5a36f9f ("drm/connector: Rename legacy TV property") failed
to update all the users of the struct drm_tv_connector_state mode field,
which resulted in a build failure in i915.

However, a subsequent commit in the same series reintroduced a mode
field in that structure, with a different semantic but the same type,
with the assumption that all previous users were updated.

Since that didn't happen, the i915 driver now compiles, but mixes
accesses to the legacy_mode field and the newer mode field, but with the
previous semantics.

This obviously doesn't work very well, so we need to update the accesses
that weren't in the legacy renaming commit.

Fixes: 1fd4a5a36f9f ("drm/connector: Rename legacy TV property")
Reported-by: Ville Syrjälä 
Signed-off-by: Maxime Ripard 
---
 drivers/gpu/drm/i915/display/intel_sdvo.c | 10 +-
 drivers/gpu/drm/i915/display/intel_tv.c   | 10 +-
 2 files changed, 10 insertions(+), 10 deletions(-)

diff --git a/drivers/gpu/drm/i915/display/intel_sdvo.c 
b/drivers/gpu/drm/i915/display/intel_sdvo.c
index 825638702ac1..5f9e748adc89 100644
--- a/drivers/gpu/drm/i915/display/intel_sdvo.c
+++ b/drivers/gpu/drm/i915/display/intel_sdvo.c
@@ -1220,7 +1220,7 @@ static bool intel_sdvo_set_tv_format(struct intel_sdvo 
*intel_sdvo,
struct intel_sdvo_tv_format format;
u32 format_map;
 
-   format_map = 1 << conn_state->tv.mode;
+   format_map = 1 << conn_state->tv.legacy_mode;
memset(, 0, sizeof(format));
memcpy(, _map, min(sizeof(format), sizeof(format_map)));
 
@@ -2323,7 +2323,7 @@ static int intel_sdvo_get_tv_modes(struct drm_connector 
*connector)
 * Read the list of supported input resolutions for the selected TV
 * format.
 */
-   format_map = 1 << conn_state->tv.mode;
+   format_map = 1 << conn_state->tv.legacy_mode;
memcpy(_res, _map,
   min(sizeof(format_map), sizeof(struct 
intel_sdvo_sdtv_resolution_request)));
 
@@ -2388,7 +2388,7 @@ intel_sdvo_connector_atomic_get_property(struct 
drm_connector *connector,
int i;
 
for (i = 0; i < intel_sdvo_connector->format_supported_num; i++)
-   if (state->tv.mode == 
intel_sdvo_connector->tv_format_supported[i]) {
+   if (state->tv.legacy_mode == 
intel_sdvo_connector->tv_format_supported[i]) {
*val = i;
 
return 0;
@@ -2444,7 +2444,7 @@ intel_sdvo_connector_atomic_set_property(struct 
drm_connector *connector,
struct intel_sdvo_connector_state *sdvo_state = 
to_intel_sdvo_connector_state(state);
 
if (property == intel_sdvo_connector->tv_format) {
-   state->tv.mode = intel_sdvo_connector->tv_format_supported[val];
+   state->tv.legacy_mode = 
intel_sdvo_connector->tv_format_supported[val];
 
if (state->crtc) {
struct drm_crtc_state *crtc_state =
@@ -3108,7 +3108,7 @@ static bool intel_sdvo_tv_create_property(struct 
intel_sdvo *intel_sdvo,
drm_property_add_enum(intel_sdvo_connector->tv_format, i,
  
tv_format_names[intel_sdvo_connector->tv_format_supported[i]]);
 
-   intel_sdvo_connector->base.base.state->tv.mode = 
intel_sdvo_connector->tv_format_supported[0];
+   intel_sdvo_connector->base.base.state->tv.legacy_mode = 
intel_sdvo_connector->tv_format_supported[0];
drm_object_attach_property(_sdvo_connector->base.base.base,
   intel_sdvo_connector->tv_format, 0);
return true;
diff --git a/drivers/gpu/drm/i915/display/intel_tv.c 
b/drivers/gpu/drm/i915/display/intel_tv.c
index a96bcfcf90a3..2b77d399f1a1 100644
--- a/drivers/gpu/drm/i915/display/intel_tv.c
+++ b/drivers/gpu/drm/i915/display/intel_tv.c
@@ -950,7 +950,7 @@ intel_disable_tv(struct intel_atomic_state *state,
 
 static const struct tv_mode *intel_tv_mode_find(const struct 
drm_connector_state *conn_state)
 {
-   int format = conn_state->tv.mode;
+   int format = conn_state->tv.legacy_mode;
 
return _modes[format];
 }
@@ -1705,7 +1705,7 @@ static void intel_tv_find_better_format(struct 
drm_connector *connector)
break;
}
 
-   connector->state->tv.mode = i;
+   connector->state->tv.legacy_mode = i;
 }
 
 static int
@@ -1863,7 +1863,7 @@ static int intel_tv_atomic_check(struct drm_connector 
*connector,
old_state = drm_atomic_get_old_connector_state(state, connector);
new_crtc_state = drm_atomic_get_new_crtc_state(state, new_state->crtc);
 
-   if (old_state->tv.mode != new_state->tv.mode ||
+   if (old_state->tv.legacy_mode != new_state->tv.legacy_mode ||
old_state->tv.margins.left != new_state-&g

Re: [PATCH] drm/i915: Fix possible null pointer dereference after drm_dbg_printer conversion

2024-02-20 Thread Maxime Ripard
On Tue, Feb 20, 2024 at 09:16:43AM +, Tvrtko Ursulin wrote:
> 
> On 19/02/2024 20:02, Rodrigo Vivi wrote:
> > On Mon, Feb 19, 2024 at 01:14:23PM +, Tvrtko Ursulin wrote:
> > > From: Tvrtko Ursulin 
> > > 
> > > Request can be NULL if no guilty request was identified so simply use
> > > engine->i915 instead.
> > > 
> > > Signed-off-by: Tvrtko Ursulin 
> > > Fixes: d50892a9554c ("drm/i915: switch from drm_debug_printer() to device 
> > > specific drm_dbg_printer()")
> > > Reported-by: Dan Carpenter 
> > > Cc: Jani Nikula 
> > > Cc: Luca Coelho 
> > > Cc: Maxime Ripard 
> > > Cc: Jani Nikula 
> > 
> > Reviewed-by: Rodrigo Vivi 
> 
> Thanks Rodrigo!
> 
> Given how d50892a9554c landed via drm-misc-next, Maxime or Thomas - could
> you take this via drm-misc-next-fixes or if there will be another
> drm-misc-next pull request?

There will be a drm-misc-next PR on thursday

Maxime


signature.asc
Description: PGP signature


Re: Re: [PULL] drm-misc-fixes

2024-02-15 Thread Maxime Ripard
Hi,

On Thu, Feb 15, 2024 at 01:41:24PM +0100, Geert Uytterhoeven wrote:
>   Hi Maxime,
> 
> On Thu, 15 Feb 2024, Maxime Ripard wrote:
> > Here's this week drm-misc-fixes PR
> > 
> > Maxime
> > 
> > drm-misc-fixes-2024-02-15:
> > A suspend/resume error fix for ivpu, a couple of scheduler fixes for
> > nouveau, a patch to support large page arrays in prime, a uninitialized
> > variable fix in crtc, a locking fix in rockchip/vop2 and a buddy
> > allocator error reporting fix.
> > The following changes since commit 5f8408aca66772d3aa9b4831577b2ac5ec41bcd9:
> > 
> >  accel/ivpu: Add job status for jobs aborted by the driver (2024-02-06 
> > 13:37:34 +0100)
> > 
> > are available in the Git repository at:
> > 
> >  git://anongit.freedesktop.org/drm/drm-misc tags/drm-misc-fixes-2024-02-15
> > 
> > for you to fetch changes up to a64056bb5a3215bd31c8ce17d609ba0f4d5c55ea:
> > 
> >  drm/tests/drm_buddy: add alloc_contiguous test (2024-02-14 15:22:21 +0100)
> > 
> > 
> > A suspend/resume error fix for ivpu, a couple of scheduler fixes for
> > nouveau, a patch to support large page arrays in prime, a uninitialized
> > variable fix in crtc, a locking fix in rockchip/vop2 and a buddy
> > allocator error reporting fix.
> 
> > Matthew Auld (1):
> >  drm/tests/drm_buddy: add alloc_contiguous test
> 
> Please drop this one.
> 
> nore...@ellerman.id.au reported a build failure on m68k (and presumably
> other 32-bit platforms) in next-20240215:
> 
> ERROR: modpost: "__umoddi3" [drivers/gpu/drm/tests/drm_buddy_test.ko] 
> undefined!
> ERROR: modpost: "__moddi3" [drivers/gpu/drm/tests/drm_buddy_test.ko] 
> undefined!
> 
> Reverting commit a64056bb5a3215bd ("drm/tests/drm_buddy: add
> alloc_contiguous test") fixes the issue.

From a quick cross-compile test with arm(32), it seems to work there
interestingly:

./tools/testing/kunit/kunit.py run \
--kunitconfig=drivers/gpu/drm//tests \
--cross_compile arm-linux-gnu- --arch arm

But I agree, with should wait for a fix or a revert before merging this.

Maxime


signature.asc
Description: PGP signature


[PULL] drm-misc-fixes

2024-02-15 Thread Maxime Ripard
Hi,

Here's this week drm-misc-fixes PR

Maxime

drm-misc-fixes-2024-02-15:
A suspend/resume error fix for ivpu, a couple of scheduler fixes for
nouveau, a patch to support large page arrays in prime, a uninitialized
variable fix in crtc, a locking fix in rockchip/vop2 and a buddy
allocator error reporting fix.
The following changes since commit 5f8408aca66772d3aa9b4831577b2ac5ec41bcd9:

  accel/ivpu: Add job status for jobs aborted by the driver (2024-02-06 
13:37:34 +0100)

are available in the Git repository at:

  git://anongit.freedesktop.org/drm/drm-misc tags/drm-misc-fixes-2024-02-15

for you to fetch changes up to a64056bb5a3215bd31c8ce17d609ba0f4d5c55ea:

  drm/tests/drm_buddy: add alloc_contiguous test (2024-02-14 15:22:21 +0100)


A suspend/resume error fix for ivpu, a couple of scheduler fixes for
nouveau, a patch to support large page arrays in prime, a uninitialized
variable fix in crtc, a locking fix in rockchip/vop2 and a buddy
allocator error reporting fix.


Arnd Bergmann (1):
  nouveau/svm: fix kvcalloc() argument order

Arunpravin Paneer Selvam (1):
  drm/buddy: Fix alloc_range() error handling code

Danilo Krummrich (2):
  drm/nouveau: don't fini scheduler if not initialized
  drm/nouveau: omit to create schedulers using the legacy uAPI

Harshit Mogalapalli (1):
  drm/rockchip: vop2: add a missing unlock in vop2_crtc_atomic_enable()

Jacek Lawrynowicz (1):
  accel/ivpu: Fix DevTLB errors on suspend/resume and recovery

Matthew Auld (1):
  drm/tests/drm_buddy: add alloc_contiguous test

Philip Yang (1):
  drm/prime: Support page array >= 4GB

Rob Clark (1):
  drm/crtc: fix uninitialized variable use even harder

 drivers/accel/ivpu/ivpu_hw_37xx.c| 44 ++
 drivers/accel/ivpu/ivpu_pm.c | 39 ++--
 drivers/gpu/drm/drm_buddy.c  |  6 ++
 drivers/gpu/drm/drm_crtc.c   |  1 +
 drivers/gpu/drm/drm_prime.c  |  2 +-
 drivers/gpu/drm/nouveau/nouveau_abi16.c  | 20 +--
 drivers/gpu/drm/nouveau/nouveau_abi16.h  |  2 +-
 drivers/gpu/drm/nouveau/nouveau_drm.c|  7 ++-
 drivers/gpu/drm/nouveau/nouveau_drv.h|  2 +-
 drivers/gpu/drm/nouveau/nouveau_exec.c   |  2 +-
 drivers/gpu/drm/nouveau/nouveau_sched.c  | 38 +++-
 drivers/gpu/drm/nouveau/nouveau_sched.h  |  6 +-
 drivers/gpu/drm/nouveau/nouveau_svm.c|  2 +-
 drivers/gpu/drm/nouveau/nouveau_uvmm.c   |  2 +-
 drivers/gpu/drm/rockchip/rockchip_drm_vop2.c |  4 +-
 drivers/gpu/drm/tests/drm_buddy_test.c   | 89 
 16 files changed, 216 insertions(+), 50 deletions(-)


signature.asc
Description: PGP signature


[PULL] drm-misc-fixes

2024-02-08 Thread Maxime Ripard
Hi,

Here's this week drm-misc-fixes PR

Maxime

drm-misc-fixes-2024-02-08:
A null pointer dereference fix for v3d, a TTM pool initialization fix,
several fixes for nouveau around register size, DMA buffer leaks and API
consistency, a multiple fixes for ivpu around MMU setup, initialization
and firmware interactions.
The following changes since commit 1c1914d6e8c6edbf5b45047419ff51abdb1dce96:

  dma-buf: heaps: Don't track CMA dma-buf pages under RssFile (2024-01-31 
19:54:58 +0530)

are available in the Git repository at:

  git://anongit.freedesktop.org/drm/drm-misc tags/drm-misc-fixes-2024-02-08

for you to fetch changes up to 5f8408aca66772d3aa9b4831577b2ac5ec41bcd9:

  accel/ivpu: Add job status for jobs aborted by the driver (2024-02-06 
13:37:34 +0100)


A null pointer dereference fix for v3d, a TTM pool initialization fix,
several fixes for nouveau around register size, DMA buffer leaks and API
consistency, a multiple fixes for ivpu around MMU setup, initialization
and firmware interactions.


Dave Airlie (1):
  nouveau/gsp: use correct size for registry rpc.

Grzegorz Trzebiatowski (1):
  accel/ivpu: Add job status for jobs aborted by the driver

Jacek Lawrynowicz (1):
  accel/ivpu: Disable d3hot_delay on all NPU generations

Krystian Pradzynski (2):
  accel/ivpu/40xx: Enable D0i3 message
  accel/ivpu/40xx: Stop passing SKU boot parameters to FW

Maxime Ripard (1):
  Merge drm-misc-next-fixes-2024-01-19 into drm-misc-fixes

Timur Tabi (2):
  drm/nouveau: fix several DMA buffer leaks
  drm/nouveau: nvkm_gsp_radix3_sg() should use nvkm_gsp_mem_ctor()

Wachowski, Karol (2):
  accel/ivpu: Force snooping for MMU writes
  accel/ivpu: Correct MMU queue size checking functions

 drivers/accel/ivpu/ivpu_drv.c |  5 +-
 drivers/accel/ivpu/ivpu_fw.c  |  1 -
 drivers/accel/ivpu/ivpu_hw_37xx.c |  2 +-
 drivers/accel/ivpu/ivpu_hw_40xx.c |  7 +-
 drivers/accel/ivpu/ivpu_job.c |  4 +-
 drivers/accel/ivpu/ivpu_mmu.c | 36 +++
 drivers/gpu/drm/nouveau/include/nvkm/subdev/gsp.h |  2 +-
 drivers/gpu/drm/nouveau/nvkm/subdev/gsp/r535.c| 79 ++-
 drivers/gpu/drm/ttm/ttm_device.c  |  9 ++-
 drivers/gpu/drm/v3d/v3d_submit.c  | 35 --
 include/uapi/drm/ivpu_accel.h |  1 +
 11 files changed, 113 insertions(+), 68 deletions(-)


signature.asc
Description: PGP signature


Re: Re: [PATCH 00/10] drm: drm debug and error logging improvements

2024-02-01 Thread Maxime Ripard
On Thu, Feb 01, 2024 at 02:51:13PM +0200, Jani Nikula wrote:
> On Tue, 16 Jan 2024, Jani Nikula  wrote:
> > This is resend and more patches on top of [1]. I don't think I've
> > changed anything since then.
> 
> Hi drm-misc maintainers -
> 
> I've got R-b from Luca, but given there's no comments outside of Intel,
> are you okay with me merging this to drm-misc?

Acked-by: Maxime Ripard 

Maxime


signature.asc
Description: PGP signature


[PULL] drm-misc-fixes

2024-02-01 Thread Maxime Ripard
Hi!

Here's this week drm-misc-fixes PR

Maxime

drm-misc-fixes-2024-02-01:
A quiet week: one fix for CMA dma-buf pages accounting, and one to
virtio to set the segment size of the virtio_gpu device.
The following changes since commit 27d19268cf394f2c78db732be0cb31852eeadb0a:

  accel/ivpu: Improve recovery and reset support (2024-01-25 10:17:37 +0100)

are available in the Git repository at:

  git://anongit.freedesktop.org/drm/drm-misc tags/drm-misc-fixes-2024-02-01

for you to fetch changes up to 1c1914d6e8c6edbf5b45047419ff51abdb1dce96:

  dma-buf: heaps: Don't track CMA dma-buf pages under RssFile (2024-01-31 
19:54:58 +0530)


A quiet week: one fix for CMA dma-buf pages accounting, and one to
virtio to set the segment size of the virtio_gpu device.


Sebastian Ott (1):
  drm/virtio: Set segment size for virtio_gpu device

T.J. Mercier (1):
  dma-buf: heaps: Don't track CMA dma-buf pages under RssFile

 drivers/dma-buf/heaps/cma_heap.c | 7 +++
 drivers/gpu/drm/virtio/virtgpu_drv.c | 1 +
 2 files changed, 4 insertions(+), 4 deletions(-)


signature.asc
Description: PGP signature


Re: Re: [PATCH] drm/atomic-helpers: remove legacy_cursor_update hacks

2024-01-28 Thread Maxime Ripard
On Thu, Jan 25, 2024 at 07:17:21PM +0100, Daniel Vetter wrote:
> On Tue, Jan 23, 2024 at 06:09:05AM +, Jason-JH Lin (林睿祥) wrote:
> > Hi Maxime, Daniel,
> > 
> > We encountered similar issue with mediatek SoCs.
> > 
> > We have found that in drm_atomic_helper_commit_rpm(), when disabling
> > the cursor plane, the old_state->legacy_cursor_update in
> > drm_atomic_wait_for_vblank() is set to true.
> > As the result, we are not actually waiting for a vlbank to wait for our
> > hardware to close the cursor plane. Subsequently, the execution
> > proceeds to drm_atomic_helper_cleanup_planes() to  free the cursor
> > buffer. This can lead to use-after-free issues with our hardware.
> > 
> > Could you please apply this patch to fix our problem?
> > Or are there any considerations for not applying this patch?
> 
> Mostly it needs someone to collect a pile of acks/tested-by and then land
> it.
> 
> I'd be _very_ happy if someone else can take care of that ...
> 
> There's also the potential issue that it might slow down some of the
> legacy X11 use-cases that really needed a non-blocking cursor, but I think
> all the drivers where this matters have switched over to the async plane
> update stuff meanwhile. So hopefully that's good.

I think there was also a regression with msm no one really figured out?

Maxime


signature.asc
Description: PGP signature


[PULL] drm-misc-fixes

2024-01-26 Thread Maxime Ripard
Hi Dave, Sima,

Here's this week drm-misc-fixes PR.

Maxime

drm-misc-fixes-2024-01-26:
Plenty of ivpu fixes to improve the general stability and debugging, a
suspend fix for the anx7625 bridge, a revert to fix an initialization
order bug between i915 and simpledrm and a documentation warning fix for
dp_mst.
The following changes since commit 6613476e225e090cc9aad49be7fa504e290dd33d:

  Linux 6.8-rc1 (2024-01-21 14:11:32 -0800)

are available in the Git repository at:

  git://anongit.freedesktop.org/drm/drm-misc tags/drm-misc-fixes-2024-01-26

for you to fetch changes up to 27d19268cf394f2c78db732be0cb31852eeadb0a:

  accel/ivpu: Improve recovery and reset support (2024-01-25 10:17:37 +0100)


Plenty of ivpu fixes to improve the general stability and debugging, a
suspend fix for the anx7625 bridge, a revert to fix an initialization
order bug between i915 and simpledrm and a documentation warning fix for
dp_mst.


Arnd Bergmann (1):
  drm/panel/raydium-rm692e5: select CONFIG_DRM_DISPLAY_DP_HELPER

Artur Weber (1):
  drm/panel: samsung-s6d7aa0: drop DRM_BUS_FLAG_DE_HIGH for lsl080al02

Bagas Sanjaya (1):
  drm/dp_mst: Separate @failing_port list in drm_dp_mst_atomic_check_mgr() 
comment

Douglas Anderson (2):
  drm/bridge: parade-ps8640: Wait for HPD when doing an AUX transfer
  drm/bridge: parade-ps8640: Make sure we drop the AUX mutex in the error 
case

Hsin-Yi Wang (1):
  drm/bridge: anx7625: Ensure bridge is suspended in disable()

Jacek Lawrynowicz (8):
  accel/ivpu: Fix for missing lock around drm_gem_shmem_vmap()
  accel/ivpu: Free buffer sgt on unbind
  accel/ivpu: Disable buffer sharing among VPU contexts
  accel/ivpu: Improve buffer object debug logs
  accel/ivpu: Disable PLL after VPU IP reset during FLR
  accel/ivpu: Fix dev open/close races with unbind
  accel/ivpu: Improve stability of ivpu_submit_ioctl()
  accel/ivpu: Improve recovery and reset support

Markus Niebel (1):
  drm: panel-simple: add missing bus flags for Tianma tm070jvhg[30/33]

Maxime Ripard (1):
  Merge v6.8-rc1 into drm-misc-fixes

Michał Winiarski (1):
  drm/tests: mm: Call drm_mm_print in drm_test_mm_debug

Pin-yen Lin (1):
  drm/bridge: parade-ps8640: Ensure bridge is suspended in .post_disable()

Thomas Zimmermann (1):
  Revert "drivers/firmware: Move sysfb_init() from device_initcall to 
subsys_initcall_sync"

Tomi Valkeinen (2):
  drm/bridge: sii902x: Fix probing race issue
  drm/bridge: sii902x: Fix audio codec unregistration

Wachowski, Karol (5):
  accel/ivpu: Dump MMU events in case of VPU boot timeout
  accel/ivpu: Call diagnose failure in ivpu_mmu_cmdq_sync()
  accel/ivpu: Add debug prints for MMU map/unmap operations
  accel/ivpu: Add diagnostic messages when VPU fails to boot or suspend
  accel/ivpu: Deprecate DRM_IVPU_PARAM_CONTEXT_PRIORITY param

Yangyu Chen (1):
  drm/ttm: allocate dummy_read_page without DMA32 on fail

 drivers/accel/ivpu/ivpu_debugfs.c |  20 +++-
 drivers/accel/ivpu/ivpu_drv.c | 124 +++-
 drivers/accel/ivpu/ivpu_drv.h |   5 +-
 drivers/accel/ivpu/ivpu_gem.c | 142 +--
 drivers/accel/ivpu/ivpu_gem.h |   3 +-
 drivers/accel/ivpu/ivpu_hw_37xx.c |  14 +--
 drivers/accel/ivpu/ivpu_hw_40xx.c |  29 -
 drivers/accel/ivpu/ivpu_ipc.c |   6 +-
 drivers/accel/ivpu/ivpu_job.c | 160 --
 drivers/accel/ivpu/ivpu_job.h |   3 +-
 drivers/accel/ivpu/ivpu_mmu.c |  22 ++--
 drivers/accel/ivpu/ivpu_mmu.h |   1 +
 drivers/accel/ivpu/ivpu_mmu_context.c |   9 ++
 drivers/accel/ivpu/ivpu_pm.c  |  52 ++---
 drivers/accel/ivpu/ivpu_pm.h  |   6 +-
 drivers/firmware/sysfb.c  |   2 +-
 drivers/gpu/drm/bridge/analogix/anx7625.c |   7 +-
 drivers/gpu/drm/bridge/analogix/anx7625.h |   2 +
 drivers/gpu/drm/bridge/parade-ps8640.c|  23 
 drivers/gpu/drm/bridge/sii902x.c  |  48 +---
 drivers/gpu/drm/display/drm_dp_mst_topology.c |   2 +
 drivers/gpu/drm/panel/Kconfig |   2 +
 drivers/gpu/drm/panel/panel-samsung-s6d7aa0.c |   2 +-
 drivers/gpu/drm/panel/panel-simple.c  |   2 +
 drivers/gpu/drm/tests/drm_mm_test.c   |   5 +-
 drivers/gpu/drm/ttm/ttm_device.c  |  12 +-
 include/uapi/drm/ivpu_accel.h |  25 +++-
 27 files changed, 413 insertions(+), 315 deletions(-)


signature.asc
Description: PGP signature


[PULL] drm-misc-next-fixes

2024-01-19 Thread Maxime Ripard
Hi,

Here's this week (and last (maybe)) drm-misc-next-fixes PR.

Thanks!
Maxime

drm-misc-next-fixes-2024-01-19:
A null pointer dereference fix for v3d and a protection fault fix for
ttm.
The following changes since commit 89fe46019a62bc1d0cb49c9615cb3520096c4bc1:

  drm/v3d: Fix support for register debugging on the RPi 4 (2024-01-09 14:21:47 
-0300)

are available in the Git repository at:

  git://anongit.freedesktop.org/drm/drm-misc tags/drm-misc-next-fixes-2024-01-19

for you to fetch changes up to 1f1626ac0428820f998245478610f452650bcab5:

  drm/ttm: fix ttm pool initialization for no-dma-device drivers (2024-01-15 
13:56:08 +0100)


A null pointer dereference fix for v3d and a protection fault fix for
ttm.


Fedor Pchelkin (1):
  drm/ttm: fix ttm pool initialization for no-dma-device drivers

Maíra Canal (1):
  drm/v3d: Free the job and assign it to NULL if initialization fails

 drivers/gpu/drm/ttm/ttm_device.c |  9 +++--
 drivers/gpu/drm/v3d/v3d_submit.c | 35 ---
 2 files changed, 35 insertions(+), 9 deletions(-)


signature.asc
Description: PGP signature


[PULL] drm-misc-next-fixes

2024-01-11 Thread Maxime Ripard
Hi,

Here's this week drm-misc-next-fixes PR.

Maxime

drm-misc-next-fixes-2024-01-11:
A fix for the v3d register readout, and two compilation fixes for
rockchip.
The following changes since commit eee706839333ec0643f1b4898a37588025bf4cb5:

  drm/imagination: pvr_device.h: fix all kernel-doc warnings (2024-01-02 
11:50:05 +0100)

are available in the Git repository at:

  git://anongit.freedesktop.org/drm/drm-misc tags/drm-misc-next-fixes-2024-01-11

for you to fetch changes up to 89fe46019a62bc1d0cb49c9615cb3520096c4bc1:

  drm/v3d: Fix support for register debugging on the RPi 4 (2024-01-09 14:21:47 
-0300)


A fix for the v3d register readout, and two compilation fixes for
rockchip.


Cristian Ciocaltea (2):
  drm/rockchip: vop2: Drop superfluous include
  drm/rockchip: vop2: Drop unused if_dclk_rate variable

Maíra Canal (1):
  drm/v3d: Fix support for register debugging on the RPi 4

 drivers/gpu/drm/rockchip/rockchip_drm_vop2.c |  4 +---
 drivers/gpu/drm/v3d/v3d_debugfs.c| 20 ++--
 2 files changed, 11 insertions(+), 13 deletions(-)


signature.asc
Description: PGP signature


Re: [PATCH 5/7] drm/uAPI: Add "preferred color format" drm property as setting for userspace

2024-01-10 Thread Maxime Ripard
Hi,

On Tue, Jan 09, 2024 at 06:11:02PM +, Andri Yngvason wrote:
> From: Werner Sembach 
> 
> Add a new general drm property "preferred color format" which can be used
> by userspace to tell the graphic drivers to which color format to use.
> 
> Possible options are:
> - auto (default/current behaviour)
> - rgb
> - ycbcr444
> - ycbcr422 (not supported by both amdgpu and i915)
> - ycbcr420
> 
> In theory the auto option should choose the best available option for the
> current setup, but because of bad internal conversion some monitors look
> better with rgb and some with ycbcr444.

I looked at the patch and I couldn't find what is supposed to happen if
you set it to something else than auto, and the driver can't match that.
Are we supposed to fallback to the "auto" behaviour, or are we suppose
to reject the mode entirely?

The combination with the active output format property suggests the
former, but we should document it explicitly.

> Also, because of bad shielded connectors and/or cables, it might be
> preferable to use the less bandwidth heavy ycbcr422 and ycbcr420 formats
> for a signal that is less deceptible to interference.
> 
> In the future, automatic color calibration for screens might also depend on
> this option being available.
> 
> Signed-off-by: Werner Sembach 
> Reported-by: Dan Carpenter 
> Signed-off-by: Andri Yngvason 
> Tested-by: Andri Yngvason 
> ---
>  drivers/gpu/drm/drm_atomic_helper.c |  4 +++
>  drivers/gpu/drm/drm_atomic_uapi.c   |  4 +++
>  drivers/gpu/drm/drm_connector.c | 50 -
>  include/drm/drm_connector.h | 17 ++
>  4 files changed, 74 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/gpu/drm/drm_atomic_helper.c 
> b/drivers/gpu/drm/drm_atomic_helper.c
> index 68ffcc0b00dca..745a43d9c5da3 100644
> --- a/drivers/gpu/drm/drm_atomic_helper.c
> +++ b/drivers/gpu/drm/drm_atomic_helper.c
> @@ -707,6 +707,10 @@ drm_atomic_helper_check_modeset(struct drm_device *dev,
>   if (old_connector_state->max_requested_bpc !=
>   new_connector_state->max_requested_bpc)
>   new_crtc_state->connectors_changed = true;
> +
> + if (old_connector_state->preferred_color_format !=
> + new_connector_state->preferred_color_format)
> + new_crtc_state->connectors_changed = true;
>   }
>  
>   if (funcs->atomic_check)
> diff --git a/drivers/gpu/drm/drm_atomic_uapi.c 
> b/drivers/gpu/drm/drm_atomic_uapi.c
> index 98d3b10c08ae1..eba5dea1249e5 100644
> --- a/drivers/gpu/drm/drm_atomic_uapi.c
> +++ b/drivers/gpu/drm/drm_atomic_uapi.c
> @@ -798,6 +798,8 @@ static int drm_atomic_connector_set_property(struct 
> drm_connector *connector,
>   state->max_requested_bpc = val;
>   } else if (property == connector->privacy_screen_sw_state_property) {
>   state->privacy_screen_sw_state = val;
> + } else if (property == connector->preferred_color_format_property) {
> + state->preferred_color_format = val;
>   } else if (connector->funcs->atomic_set_property) {
>   return connector->funcs->atomic_set_property(connector,
>   state, property, val);
> @@ -881,6 +883,8 @@ drm_atomic_connector_get_property(struct drm_connector 
> *connector,
>   *val = state->max_requested_bpc;
>   } else if (property == connector->privacy_screen_sw_state_property) {
>   *val = state->privacy_screen_sw_state;
> + } else if (property == connector->preferred_color_format_property) {
> + *val = state->preferred_color_format;
>   } else if (connector->funcs->atomic_get_property) {
>   return connector->funcs->atomic_get_property(connector,
>   state, property, val);
> diff --git a/drivers/gpu/drm/drm_connector.c b/drivers/gpu/drm/drm_connector.c
> index 30d62e505d188..4de48a38792cf 100644
> --- a/drivers/gpu/drm/drm_connector.c
> +++ b/drivers/gpu/drm/drm_connector.c
> @@ -1061,6 +1061,14 @@ static const struct drm_prop_enum_list 
> drm_dp_subconnector_enum_list[] = {
>   { DRM_MODE_SUBCONNECTOR_Native,  "Native"}, /* DP */
>  };
>  
> +static const struct drm_prop_enum_list 
> drm_preferred_color_format_enum_list[] = {
> + { 0, "auto" },
> + { DRM_COLOR_FORMAT_RGB444, "rgb" },
> + { DRM_COLOR_FORMAT_YCBCR444, "ycbcr444" },
> + { DRM_COLOR_FORMAT_YCBCR422, "ycbcr422" },
> + { DRM_COLOR_FORMAT_YCBCR420, "ycbcr420" },
> +};
> +
>  static const struct drm_prop_enum_list drm_active_color_format_enum_list[] = 
> {
>   { 0, "not applicable" },
>   { DRM_COLOR_FORMAT_RGB444, "rgb" },
> @@ -1398,11 +1406,20 @@ static const u32 dp_colorspaces =
>   *   drm_connector_attach_max_bpc_property() to create and attach the
>   *   property to the connector during initialization.
>   *
> + * preferred 

[PULL] drm-misc-next-fixes

2024-01-04 Thread Maxime Ripard
Hi!

Here's this week drm-misc-next-fixes PR

Maxime

drm-misc-next-fixes-2024-01-04:
One fix for drm/plane to avoid a use-after-free and some additional
warnings to prevent more of these occurences, a lock inversion
dependency fix and an indentation fix for drm/rockchip, and some doc
warning fixes for imagination and gpuvm.
The following changes since commit 933a2a376fb3f22ba4774f74233571504ac56b02:

  drm: using mul_u32_u32() requires linux/math64.h (2023-12-19 15:29:17 +0200)

are available in the Git repository at:

  git://anongit.freedesktop.org/drm/drm-misc tags/drm-misc-next-fixes-2024-01-04

for you to fetch changes up to eee706839333ec0643f1b4898a37588025bf4cb5:

  drm/imagination: pvr_device.h: fix all kernel-doc warnings (2024-01-02 
11:50:05 +0100)


One fix for drm/plane to avoid a use-after-free and some additional
warnings to prevent more of these occurences, a lock inversion
dependency fix and an indentation fix for drm/rockchip, and some doc
warning fixes for imagination and gpuvm.


Andy Yan (1):
  drm/rockchip: vop2: Avoid use regmap_reinit_cache at runtime

Jiapeng Chong (1):
  drm/rockchip: vop2: clean up some inconsistent indenting

Randy Dunlap (2):
  drm/gpuvm: fix all kernel-doc warnings in include/drm/drm_gpuvm.h
  drm/imagination: pvr_device.h: fix all kernel-doc warnings

Ville Syrjälä (2):
  drm: Don't unref the same fb many times by mistake due to deadlock 
handling
  drm: Warn when freeing a framebuffer that's still on a list

 drivers/gpu/drm/drm_framebuffer.c|  5 +-
 drivers/gpu/drm/drm_plane.c  |  1 +
 drivers/gpu/drm/imagination/pvr_device.h | 46 
 drivers/gpu/drm/rockchip/rockchip_drm_vop2.c | 12 ++---
 include/drm/drm_gpuvm.h  | 80 
 5 files changed, 79 insertions(+), 65 deletions(-)


signature.asc
Description: PGP signature


Re: [PATCH v9 09/25] drm/modes: Move named modes parsing to a separate function

2024-01-03 Thread Maxime Ripard
Hi Dave,

Happy new year :)

On Tue, Jan 02, 2024 at 03:12:26PM +, Dave Stevenson wrote:
> Hi Maxime
> 
> On Mon, 14 Nov 2022 at 13:00, Maxime Ripard  wrote:
> >
> > The current construction of the named mode parsing doesn't allow to extend
> > it easily. Let's move it to a separate function so we can add more
> > parameters and modes.
> >
> > In order for the tests to still pass, some extra checks are needed, so
> > it's not a 1:1 move.
> >
> > Reviewed-by: Noralf Trønnes 
> > Tested-by: Mateusz Kwiatkowski 
> > Signed-off-by: Maxime Ripard 
> >
> > ---
> > Changes in v7:
> > - Add Noralf Reviewed-by
> >
> > Changes in v6:
> > - Simplify the test for connection status extras
> > - Simplify the code path to call drm_mode_parse_cmdline_named_mode
> >
> > Changes in v4:
> > - Fold down all the named mode patches that were split into a single
> >   patch again to maintain bisectability
> > ---
> >  drivers/gpu/drm/drm_modes.c | 70 
> > +
> >  1 file changed, 58 insertions(+), 12 deletions(-)
> >
> > diff --git a/drivers/gpu/drm/drm_modes.c b/drivers/gpu/drm/drm_modes.c
> > index 71c050c3ee6b..37542612912b 100644
> > --- a/drivers/gpu/drm/drm_modes.c
> > +++ b/drivers/gpu/drm/drm_modes.c
> > @@ -2229,6 +2229,51 @@ static const char * const 
> > drm_named_modes_whitelist[] = {
> > "PAL",
> >  };
> >
> > +static int drm_mode_parse_cmdline_named_mode(const char *name,
> > +unsigned int name_end,
> > +struct drm_cmdline_mode 
> > *cmdline_mode)
> > +{
> > +   unsigned int i;
> > +
> > +   if (!name_end)
> > +   return 0;
> > +
> > +   /* If the name starts with a digit, it's not a named mode */
> > +   if (isdigit(name[0]))
> > +   return 0;
> > +
> > +   /*
> > +* If there's an equal sign in the name, the command-line
> > +* contains only an option and no mode.
> > +*/
> > +   if (strnchr(name, name_end, '='))
> > +   return 0;
> > +
> > +   /* The connection status extras can be set without a mode. */
> > +   if (name_end == 1 &&
> > +   (name[0] == 'd' || name[0] == 'D' || name[0] == 'e'))
> > +   return 0;
> > +
> > +   /*
> > +* We're sure we're a named mode at this point, iterate over the
> > +* list of modes we're aware of.
> > +*/
> > +   for (i = 0; i < ARRAY_SIZE(drm_named_modes_whitelist); i++) {
> > +   int ret;
> > +
> > +   ret = str_has_prefix(name, drm_named_modes_whitelist[i]);
> > +   if (ret != name_end)
> > +   continue;
> > +
> > +   strcpy(cmdline_mode->name, drm_named_modes_whitelist[i]);
> > +   cmdline_mode->specified = true;
> > +
> > +   return 1;
> > +   }
> > +
> > +   return -EINVAL;
> > +}
> > +
> >  /**
> >   * drm_mode_parse_command_line_for_connector - parse command line modeline 
> > for connector
> >   * @mode_option: optional per connector mode option
> > @@ -2265,7 +2310,7 @@ bool drm_mode_parse_command_line_for_connector(const 
> > char *mode_option,
> > const char *bpp_ptr = NULL, *refresh_ptr = NULL, *extra_ptr = NULL;
> > const char *options_ptr = NULL;
> > char *bpp_end_ptr = NULL, *refresh_end_ptr = NULL;
> > -   int i, len, ret;
> > +   int len, ret;
> >
> > memset(mode, 0, sizeof(*mode));
> > mode->panel_orientation = DRM_MODE_PANEL_ORIENTATION_UNKNOWN;
> > @@ -2306,18 +2351,19 @@ bool 
> > drm_mode_parse_command_line_for_connector(const char *mode_option,
> > parse_extras = true;
> > }
> >
> > -   /* First check for a named mode */
> > -   for (i = 0; i < ARRAY_SIZE(drm_named_modes_whitelist); i++) {
> > -   ret = str_has_prefix(name, drm_named_modes_whitelist[i]);
> > -   if (ret == mode_end) {
> > -   if (refresh_ptr)
> > -   return false; /* named + refresh is invalid 
> > */
> > +   if (!mode_end)
> > +   return false;
> 
> I'm chasing down a change in behaviour between 6.1 and 6.6, and this
> patch seems to be a

[PULL] drm-misc-next-fixes

2023-12-21 Thread Maxime Ripard
Hi,

Here's this week drm-misc-next-fixes PR

Thanks!
Maxime

drm-misc-next-fixes-2023-12-21:
More fixes for the new imagination drier, a DT node refcount fix for the
new aux bridge driver and a missing header fix for the LUT management
code.
The following changes since commit b1a2aa9bcbb88a7dc1c4df98dbf4f4df9ca79c9f:

  drm: ci: Update xfails (2023-12-13 15:18:30 -0300)

are available in the Git repository at:

  git://anongit.freedesktop.org/drm/drm-misc tags/drm-misc-next-fixes-2023-12-21

for you to fetch changes up to 933a2a376fb3f22ba4774f74233571504ac56b02:

  drm: using mul_u32_u32() requires linux/math64.h (2023-12-19 15:29:17 +0200)


More fixes for the new imagination drier, a DT node refcount fix for the
new aux bridge driver and a missing header fix for the LUT management
code.


Dmitry Baryshkov (1):
  drm/bridge: properly refcount DT nodes in aux bridge drivers

Donald Robson (4):
  drm/imagination: Fixed infinite loop in pvr_vm_mips_map()
  drm/imagination: Fixed oops when misusing ioctl CREATE_HWRT_DATASET
  drm/imagination: Fix ERR_PTR test on pointer to pointer.
  drm/imagination: Fix error path in pvr_vm_create_context

Stephen Rothwell (1):
  drm: using mul_u32_u32() requires linux/math64.h

 drivers/gpu/drm/bridge/aux-bridge.c   |  3 ++-
 drivers/gpu/drm/bridge/aux-hpd-bridge.c   |  4 ++--
 drivers/gpu/drm/imagination/pvr_hwrt.c| 27 ++-
 drivers/gpu/drm/imagination/pvr_vm.c  | 30 ++
 drivers/gpu/drm/imagination/pvr_vm_mips.c |  6 +++---
 include/drm/drm_color_mgmt.h  |  1 +
 6 files changed, 36 insertions(+), 35 deletions(-)


signature.asc
Description: PGP signature


[PULL] drm-misc-next

2023-12-14 Thread Maxime Ripard
Hi,

Here's this week (and probably last for 6.8) drm-misc-next PR.

Thanks!
Maxime

drm-misc-next-2023-12-14:
drm-misc-next for $kernel-version:

UAPI Changes:

Cross-subsystem Changes:
 - A few fixes for usb/typec

Core Changes:
 - ci: Updates to the defconfig, igt version, etc.
 - writeback: Move the atomic_check helper from the encoder to connector

Driver Changes:
 - rockchip: Add support for rk3588
 - xe: Update the TODO list
 - panel:
   - nv3052c: Register documentation, init sequence improvements and
 support for the Fascontek FS035VG158
   - st7701: Add support for the Anbernic RG-ARC
   - new driver: Synaptics R63353 panel controller, Ilitek ILI9805 panel
 controller
   - new panel: AUO G156HAN04.0
The following changes since commit 90d50b8d85834e73536fdccd5aa913b30494fef0:

  drm/mipi-dsi: Fix detach call without attach (2023-12-07 09:22:47 +0200)

are available in the Git repository at:

  git://anongit.freedesktop.org/drm/drm-misc tags/drm-misc-next-2023-12-14

for you to fetch changes up to b1a2aa9bcbb88a7dc1c4df98dbf4f4df9ca79c9f:

  drm: ci: Update xfails (2023-12-13 15:18:30 -0300)


drm-misc-next for $kernel-version:

UAPI Changes:

Cross-subsystem Changes:
 - A few fixes for usb/typec

Core Changes:
 - ci: Updates to the defconfig, igt version, etc.
 - writeback: Move the atomic_check helper from the encoder to connector

Driver Changes:
 - rockchip: Add support for rk3588
 - xe: Update the TODO list
 - panel:
   - nv3052c: Register documentation, init sequence improvements and
 support for the Fascontek FS035VG158
   - st7701: Add support for the Anbernic RG-ARC
   - new driver: Synaptics R63353 panel controller, Ilitek ILI9805 panel
 controller
   - new panel: AUO G156HAN04.0


Alex Bee (1):
  drm/imagination: vm: Fix heap lookup condition

Andy Yan (13):
  drm/rockchip: move output interface related definition to 
rockchip_drm_drv.h
  Revert "drm/rockchip: vop2: Use regcache_sync() to fix suspend/resume"
  drm/rockchip: vop2: set half_block_en bit in all mode
  drm/rockchip: vop2: clear afbc en and transform bit for cluster window at 
linear mode
  drm/rockchip: vop2: Add write mask for VP config done
  drm/rockchip: vop2: Set YUV/RGB overlay mode
  drm/rockchip: vop2: set bg dly and prescan dly at vop2_post_config
  drm/rockchip: vop2: rename grf to sys_grf
  dt-bindings: display: vop2: Add rk3588 support
  dt-bindings: rockchip,vop2: Add more endpoint definition
  drm/rockchip: vop2: Add support for rk3588
  drm/rockchip: vop2: rename VOP_FEATURE_OUTPUT_10BIT to 
VOP2_VP_FEATURE_OUTPUT_10BIT
  MAINTAINERS: Add myself as a reviewer for rockchip drm

Chris Morgan (3):
  drm/panel: st7701: Fix AVCL calculation
  dt-bindings: display: st7701: Add Anbernic RG-ARC panel
  drm/panel: st7701: Add Anbernic RG-ARC Panel Support

Dan Carpenter (1):
  drm/imagination: Move dereference after NULL check in 
pvr_mmu_backing_page_init()

Dario Binacchi (2):
  drm/panel: synaptics-r63353: adjust the includes
  drm/panel: ilitek-ili9805: adjust the includes

Dmitry Baryshkov (2):
  drm/atomic-helper: rename drm_atomic_helper_check_wb_encoder_state
  drm/vkms: move wb's atomic_check from encoder to connector

Elmar Albert (2):
  dt-bindings: display: simple: Add AUO G156HAN04.0 LVDS display
  drm/panel: simple: Add AUO G156HAN04.0 LVDS display support

John Watts (7):
  drm/panel: nv3052c: Document known register names
  drm/panel: nv3052c: Add SPI device IDs
  drm/panel: nv3052c: Allow specifying registers per panel
  drm/panel: nv3052c: Add Fascontek FS035VG158 LCD display
  dt-bindings: display: panel: Clean up leadtek,ltk035c5444t properties
  dt-bindings: vendor-prefixes: Add fascontek
  dt-bindings: display: panel: add Fascontek FS035VG158 panel

Marek Szyprowski (1):
  drm/debugfs: fix potential NULL pointer dereference

Matthew Brost (1):
  drm/doc/rfc: Mark long running workload as complete.

Maxime Ripard (1):
  drm/vc4: hdmi: Create destroy state implementation

Michael Trimarchi (4):
  drm/panel: Add Synaptics R63353 panel driver
  dt-bindings: display: panel: Add Ilitek ili9805 panel controller
  drm/panel: Add Ilitek ILI9805 panel driver
  drm/panel: ilitek-ili9805: add support for Tianma TM041XDHG01 panel

Nathan Chancellor (3):
  usb: typec: nb7vpq904m: Only select DRM_AUX_BRIDGE with OF
  usb: typec: qcom-pmic-typec: Only select DRM_AUX_HPD_BRIDGE with OF
  drm/bridge: Return NULL instead of plain 0 in 
drm_dp_hpd_bridge_register() stub

Pin-yen Lin (1):
  drm/edp-panel: Move the KDC panel to a separate group

Randy Dunlap (3):
  drm/fourcc: fix spelling/typos
  drm/drm_modeset_helper_vtables.h: fix typos/spellos
  drm/uapi: drm_mode.h: fix spellos and gr

Re: (subset) [PATCH] drm/crtc: fix uninitialized variable use

2023-12-08 Thread Maxime Ripard
On Fri, 08 Dec 2023 15:12:38 +0200, Jani Nikula wrote:
> Commit 3823119b9c2b ("drm/crtc: Fix uninit-value bug in
> drm_mode_setcrtc") was supposed to fix use of an uninitialized variable,
> but introduced another.
> 
> num_connectors is only initialized if crtc_req->count_connectors > 0,
> but it's used regardless. Fix it.
> 
> [...]

Applied to drm/drm-misc (drm-misc-fixes).

Thanks!
Maxime



Re: [PATCH RESEND AGAIN v2 0/2] Add drm_dbg_ratelimited()

2023-12-07 Thread Maxime Ripard
On Thu, Dec 07, 2023 at 10:23:08AM +0100, Andi Shyti wrote:
> Hi Thomas and Maxime,
> 
> thanks for the answer,
> 
> On Thu, Dec 07, 2023 at 10:10:55AM +0100, Maxime Ripard wrote:
> > On Wed, Dec 06, 2023 at 10:09:46PM +0100, Andi Shyti wrote:
> > > This is the second time I am resending this series in its v2. It
> > > has been reviewd, acked, blessed, discussed, rectified, assessed,
> > > authorized, validated, glorified, praised, demanded, approved,
> > > and yet, I don't understand why no one is merging it.
> > 
> > $ ./scripts/get_maintainer.pl -f drivers/gpu/drm/i915/
> > Jani Nikula  (supporter:INTEL DRM DRIVERS 
> > (excluding Poulsbo, Moorestow...)
> > Joonas Lahtinen  (supporter:INTEL DRM 
> > DRIVERS (excluding Poulsbo, Moorestow...)
> > Rodrigo Vivi  (supporter:INTEL DRM DRIVERS 
> > (excluding Poulsbo, Moorestow...)
> > Tvrtko Ursulin  (supporter:INTEL DRM 
> > DRIVERS (excluding Poulsbo, Moorestow...)
> > David Airlie  (maintainer:DRM DRIVERS)
> > Daniel Vetter  (maintainer:DRM DRIVERS)
> > intel-gfx@lists.freedesktop.org (open list:INTEL DRM DRIVERS (excluding 
> > Poulsbo, Moorestow...)
> > dri-de...@lists.freedesktop.org (open list:DRM DRIVERS)
> > linux-ker...@vger.kernel.org (open list)
> > 
> > You've Cc'd none of the i915 maintainers, that's why it's been stuck.
> > 
> > Jani, Joonas, Rodrigo, Tvrtko, could you have a look at this?
> 
> The main change here is in drm_print.h, though and there is just
> an example of usage in i915. I though this should go through the
> drm branch.
> 
> Is it OK if I push it in drm-intel-next?

Sure, and you can add my acked-by on the first

Maxime


signature.asc
Description: PGP signature


[Intel-gfx] [PULL] drm-misc-next

2023-12-07 Thread Maxime Ripard
Hi Dave, Sima,

Here's this week drm-misc-next PR

Maxime

drm-misc-next-2023-12-07:
drm-misc-next for 6.8:

UAPI Changes:
  - Remove Userspace Mode-Setting ioctls
  - v3d: New uapi to handle jobs involving the CPU

Cross-subsystem Changes:

Core Changes:
  - atomic: Add support for FB-less planes which got reverted a bit
later for lack of IGT tests and userspace code, Dump private objects
state in drm_state_dump.
  - dma-buf: Add fence deadline support
  - encoder: Create per-encoder debugfs directory, move the bridge chain
file to that directory

Driver Changes:
  - Include drm_auth.h in driver that use it but don't include it, Drop
drm_plane_helper.h from drivers that include it but don't use it
  - imagination: Plenty of small fixes
  - panfrost: Improve interrupt handling at poweroff
  - qaic: Convert to persistent DRM devices
  - tidss: Support for the AM62A7, a few probe improvements, some cleanups
  - v3d: Support for jobs involving the CPU

  - bridge:
- Create transparent aux-bridge for DP/USB-C
- lt8912b: Add suspend/resume support and power regulator support

  - panel:
- himax-hx8394: Drop prepare, unprepare and shutdown logic, Support
  panel rotation
- New panels: BOE BP101WX1-100, Powkiddy X55, Ampire AM8001280G,
  Evervision VGG644804, SDC ATNA45AF01
The following changes since commit a13fee31f56449fc600d9e064c7b32302f92dcef:

  Merge v6.7-rc3 into drm-next (2023-11-28 11:55:56 +0100)

are available in the Git repository at:

  git://anongit.freedesktop.org/drm/drm-misc tags/drm-misc-next-2023-12-07

for you to fetch changes up to 90d50b8d85834e73536fdccd5aa913b30494fef0:

  drm/mipi-dsi: Fix detach call without attach (2023-12-07 09:22:47 +0200)


drm-misc-next for 6.8:

UAPI Changes:
  - Remove Userspace Mode-Setting ioctls
  - v3d: New uapi to handle jobs involving the CPU

Cross-subsystem Changes:

Core Changes:
  - atomic: Add support for FB-less planes which got reverted a bit
later for lack of IGT tests and userspace code, Dump private objects
state in drm_state_dump.
  - dma-buf: Add fence deadline support
  - encoder: Create per-encoder debugfs directory, move the bridge chain
file to that directory

Driver Changes:
  - Include drm_auth.h in driver that use it but don't include it, Drop
drm_plane_helper.h from drivers that include it but don't use it
  - imagination: Plenty of small fixes
  - panfrost: Improve interrupt handling at poweroff
  - qaic: Convert to persistent DRM devices
  - tidss: Support for the AM62A7, a few probe improvements, some cleanups
  - v3d: Support for jobs involving the CPU

  - bridge:
- Create transparent aux-bridge for DP/USB-C
- lt8912b: Add suspend/resume support and power regulator support

  - panel:
- himax-hx8394: Drop prepare, unprepare and shutdown logic, Support
  panel rotation
- New panels: BOE BP101WX1-100, Powkiddy X55, Ampire AM8001280G,
  Evervision VGG644804, SDC ATNA45AF01


Abel Vesa (1):
  drm/panel-edp: Add SDC ATNA45AF01

Abhinav Kumar (2):
  drm: improve the documentation of connector hpd ops
  drm: remove drm_bridge_hpd_disable() from drm_bridge_connector_destroy()

Alex Bee (1):
  dt-bindings: gpu: mali-utgard: Add Rockchip RK3128 compatible

Andrew Davis (1):
  drm/omapdrm: Improve check for contiguous buffers

André Almeida (1):
  drm: Refuse to async flip with atomic prop changes

AngeloGioacchino Del Regno (3):
  drm/panfrost: Ignore core_mask for poweroff and disable PWRTRANS irq
  drm/panfrost: Add gpu_irq, mmu_irq to struct panfrost_device
  drm/panfrost: Synchronize and disable interrupts before powering off

Aradhya Bhatia (2):
  dt-bindings: display: ti: Add support for am62a7 dss
  drm/tidss: Add support for AM62A7 DSS

Arnd Bergmann (1):
  drm/imagination: move update_logtype() into ifdef section

Bert Karwatzki (1):
  drm/sched: Partial revert of "Qualify drm_sched_wakeup() by 
drm_sched_entity_is_ready()"

Boris Brezillon (1):
  drm/gpuvm: Let drm_gpuvm_bo_put() report when the vm_bo object is 
destroyed

Carl Vanderlip (2):
  accel/qaic: Increase number of in_reset states
  accel/qaic: Expand DRM device lifecycle

Chris Morgan (6):
  drm/panel: himax-hx8394: Drop prepare/unprepare tracking
  drm/panel: himax-hx8394: Drop shutdown logic
  dt-bindings: display: Document Himax HX8394 panel rotation
  drm/panel: himax-hx8394: Add Panel Rotation Support
  dt-bindings: display: himax-hx8394: Add Powkiddy X55 panel
  drm/panel: himax-hx8394: Add Support for Powkiddy X55 panel

Colin Ian King (1):
  drm/imagination: Fix a couple of spelling mistakes in literal strings

Dan Carpenter (5):
  drm/imagination: Fix error codes in pvr_device_clk_init()
  drm/imagination: Fix IS_ERR() vs NULL bug in pvr_request_firmware()
   

Re: [Intel-gfx] [PATCH RESEND AGAIN v2 0/2] Add drm_dbg_ratelimited()

2023-12-07 Thread Maxime Ripard
On Wed, Dec 06, 2023 at 10:09:46PM +0100, Andi Shyti wrote:
> This is the second time I am resending this series in its v2. It
> has been reviewd, acked, blessed, discussed, rectified, assessed,
> authorized, validated, glorified, praised, demanded, approved,
> and yet, I don't understand why no one is merging it.

$ ./scripts/get_maintainer.pl -f drivers/gpu/drm/i915/
Jani Nikula  (supporter:INTEL DRM DRIVERS 
(excluding Poulsbo, Moorestow...)
Joonas Lahtinen  (supporter:INTEL DRM DRIVERS 
(excluding Poulsbo, Moorestow...)
Rodrigo Vivi  (supporter:INTEL DRM DRIVERS (excluding 
Poulsbo, Moorestow...)
Tvrtko Ursulin  (supporter:INTEL DRM DRIVERS 
(excluding Poulsbo, Moorestow...)
David Airlie  (maintainer:DRM DRIVERS)
Daniel Vetter  (maintainer:DRM DRIVERS)
intel-gfx@lists.freedesktop.org (open list:INTEL DRM DRIVERS (excluding 
Poulsbo, Moorestow...)
dri-de...@lists.freedesktop.org (open list:DRM DRIVERS)
linux-ker...@vger.kernel.org (open list)

You've Cc'd none of the i915 maintainers, that's why it's been stuck.

Jani, Joonas, Rodrigo, Tvrtko, could you have a look at this?

Maxime


signature.asc
Description: PGP signature


Re: [Intel-gfx] [RFC] drm: enable W=1 warnings by default across the subsystem

2023-11-30 Thread Maxime Ripard
On Thu, Nov 30, 2023 at 11:46:00AM +0200, Jani Nikula wrote:
> On Thu, 30 Nov 2023, Javier Martinez Canillas  wrote:
> > Maxime Ripard  writes:
> >
> >> Hi,
> >>
> >> On Thu, Nov 30, 2023 at 10:52:17AM +0200, Jani Nikula wrote:
> >>> On Wed, 29 Nov 2023, Hamza Mahfooz  wrote:
> >>> > Cc: Nathan Chancellor 
> >>> >
> >>> > On 11/29/23 13:12, Jani Nikula wrote:
> >>> >> At least the i915 and amd drivers enable a bunch more compiler warnings
> >>> >> than the kernel defaults.
> >>> >> 
> >>> >> Extend the W=1 warnings to the entire drm subsystem by default. Use the
> >>> >> copy-pasted warnings from scripts/Makefile.extrawarn with
> >>> >> s/KBUILD_CFLAGS/subdir-ccflags-y/ to make it easier to compare and keep
> >>> >> up with them in the future.
> >>> >> 
> >>> >> This is similar to the approach currently used in i915.
> >>> >> 
> >>> >> Some of the -Wextra warnings do need to be disabled, just like in
> >>> >> Makefile.extrawarn, but take care to not disable them for W=2 or W=3
> >>> >> builds, depending on the warning.
> >>> >
> >>> > I think this should go in after drm-misc-next has a clean build (for
> >>> > COMPILE_TEST builds) with this patch applied. Otherwise, it will break a
> >>> > lot of build configs.
> >>> 
> >>> Oh, I'm absolutely not suggesting this should be merged before known
> >>> warnings have been addressed one way or another. Either by fixing them
> >>> or by disabling said warning in driver local Makefiles, depending on the
> >>> case.
> >>
> >> I'm all for it, but yeah, we need some easy way to opt-in/opt-out. Some
> >> drivers are pretty much unmaintained now and are likely to never fix
> >> those warnings.
> 
> Then I'd go for enabling in drm level and disabling individual warnings
> in the driver Makefile level if they won't get fixed.
> 
> > Maybe add a Kconfig symbol for it instead of making unconditional?
> >
> > Something like:
> >
> > +# Unconditionally enable W=1 warnings locally
> > +# --- begin copy-paste W=1 warnings from scripts/Makefile.extrawarn
> > +subdir-ccflags-$(CONFIG_DRM_EXTRA_CHECKS)  += -Wextra -Wunused 
> > -Wno-unused-parameter
> > ...
> 
> Then we'll have a ping pong of people not using W=1 or
> CONFIG_DRM_EXTRA_CHECKS introducing warnings, and people using them
> fixing the warnings...
> 
> I really do think making it unconditional is the only way.

Yeah, I agree.

Plus, if we need to have an extra Kconfig option, it's pretty equivalent
to using W=1

Maxime


signature.asc
Description: PGP signature


Re: [Intel-gfx] [RFC] drm: enable W=1 warnings by default across the subsystem

2023-11-30 Thread Maxime Ripard
Hi,

On Thu, Nov 30, 2023 at 10:52:17AM +0200, Jani Nikula wrote:
> On Wed, 29 Nov 2023, Hamza Mahfooz  wrote:
> > Cc: Nathan Chancellor 
> >
> > On 11/29/23 13:12, Jani Nikula wrote:
> >> At least the i915 and amd drivers enable a bunch more compiler warnings
> >> than the kernel defaults.
> >> 
> >> Extend the W=1 warnings to the entire drm subsystem by default. Use the
> >> copy-pasted warnings from scripts/Makefile.extrawarn with
> >> s/KBUILD_CFLAGS/subdir-ccflags-y/ to make it easier to compare and keep
> >> up with them in the future.
> >> 
> >> This is similar to the approach currently used in i915.
> >> 
> >> Some of the -Wextra warnings do need to be disabled, just like in
> >> Makefile.extrawarn, but take care to not disable them for W=2 or W=3
> >> builds, depending on the warning.
> >
> > I think this should go in after drm-misc-next has a clean build (for
> > COMPILE_TEST builds) with this patch applied. Otherwise, it will break a
> > lot of build configs.
> 
> Oh, I'm absolutely not suggesting this should be merged before known
> warnings have been addressed one way or another. Either by fixing them
> or by disabling said warning in driver local Makefiles, depending on the
> case.

I'm all for it, but yeah, we need some easy way to opt-in/opt-out. Some
drivers are pretty much unmaintained now and are likely to never fix
those warnings.

Maxime


signature.asc
Description: PGP signature


[Intel-gfx] [PULL] drm-misc-next

2023-11-30 Thread Maxime Ripard
Hi,

Here's this week drm-misc-next PR

Thanks!
Maxime

drm-misc-next-2023-11-30:
drm-misc-next for 6.8:

UAPI Changes:
 - Introduction of DRM_CAP_ATOMIC_ASYNC_PAGE_FLIP
 - Introduction of DRM_CLIENT_CAP_CURSOR_PLANE_HOTSPOT

Cross-subsystem Changes:
 - fbdev: Convert a big chunks of drivers to helper macros

Core Changes:
 - atomic: Add support for mouse hotspots

Driver Changes:
 - ast: Model Detection improvements
 - imagination: plenty of fixes
 - nouveau: use GPUVM, scheduling improvements
The following changes since commit a13fee31f56449fc600d9e064c7b32302f92dcef:

  Merge v6.7-rc3 into drm-next (2023-11-28 11:55:56 +0100)

are available in the Git repository at:

  git://anongit.freedesktop.org/drm/drm-misc tags/drm-misc-next-2023-11-30

for you to fetch changes up to 9ee33dc47772724ff583b060bb37c62b92b2d9c4:

  drm/imagination: Fix IS_ERR() vs NULL bug in pvr_request_firmware() 
(2023-11-30 09:16:59 +0100)


drm-misc-next for 6.8:

UAPI Changes:
 - Introduction of DRM_CAP_ATOMIC_ASYNC_PAGE_FLIP
 - Introduction of DRM_CLIENT_CAP_CURSOR_PLANE_HOTSPOT

Cross-subsystem Changes:
 - fbdev: Convert a big chunks of drivers to helper macros

Core Changes:
 - atomic: Add support for mouse hotspots

Driver Changes:
 - ast: Model Detection improvements
 - imagination: plenty of fixes
 - nouveau: use GPUVM, scheduling improvements


André Almeida (1):
  drm: Refuse to async flip with atomic prop changes

Bert Karwatzki (1):
  drm/sched: Partial revert of "Qualify drm_sched_wakeup() by 
drm_sched_entity_is_ready()"

Colin Ian King (1):
  drm/imagination: Fix a couple of spelling mistakes in literal strings

Dan Carpenter (2):
  drm/imagination: Fix error codes in pvr_device_clk_init()
  drm/imagination: Fix IS_ERR() vs NULL bug in pvr_request_firmware()

Danilo Krummrich (6):
  drm/nouveau: use GPUVM common infrastructure
  drm/nouveau: implement 1:1 scheduler - entity relationship
  drm/nouveau: enable dynamic job-flow control
  drm/imagination: vm: prevent duplicate drm_gpuvm_bo instances
  drm/imagination: vm: check for drm_gpuvm_range_valid()
  drm/imagination: vm: fix drm_gpuvm reference count

Dario Binacchi (1):
  drm/bridge: Fix typo in post_disable() description

Donald Robson (1):
  drm/imagination: Numerous documentation fixes.

Hsin-Yi Wang (3):
  drm/panel-edp: Add override_edid_mode quirk for generic edp
  drm/panel-edp: Add auo_b116xa3_mode
  drm/panel-edp: Avoid adding multiple preferred modes

Javier Martinez Canillas (5):
  drm: Allow drivers to indicate the damage helpers to ignore damage clips
  drm/virtio: Disable damage clipping if FB changed since last page-flip
  drm/vmwgfx: Disable damage clipping if FB changed since last page-flip
  drm/plane: Extend damage tracking kernel-doc
  drm/todo: Add entry about implementing buffer age for damage tracking

Jean Delvare (1):
  drm/loongson: Add platform dependency

Liu Ying (1):
  drm/bridge: imx93-mipi-dsi: Fix a couple of building warnings

Luben Tuikov (4):
  drm/sched: Fix bounds limiting when given a malformed entity
  drm/sched: Rename priority MIN to LOW
  drm/sched: Reverse run-queue priority enumeration
  drm/sched: Fix compilation issues with DRM priority rename

Michael Banack (1):
  drm: Introduce documentation for hotspot properties

Rajneesh Bhardwaj (1):
  drm/ttm: Schedule delayed_delete worker closer

Rob Herring (1):
  drm: Use device_get_match_data()

Simon Ser (2):
  drm: allow DRM_MODE_PAGE_FLIP_ASYNC for atomic commits
  drm: introduce DRM_CAP_ATOMIC_ASYNC_PAGE_FLIP

Thomas Hellström (1):
  Documentation/gpu: VM_BIND locking document

Thomas Zimmermann (43):
  Merge drm/drm-next into drm-misc-next
  drm/ast: Turn ioregs_lock to modeset_lock
  drm/ast: Rework I/O register setup
  drm/ast: Retrieve I/O-memory ranges without ast device
  drm/ast: Add I/O helpers without ast device
  drm/ast: Enable VGA without ast device instance
  drm/ast: Enable MMIO without ast device instance
  drm/ast: Partially implement POST without ast device instance
  drm/ast: Add enum ast_config_mode
  drm/ast: Detect ast device type and config mode without ast device
  drm/ast: Move detection code into PCI probe helper
  fbdev/acornfb: Fix name of fb_ops initializer macro
  fbdev/sm712fb: Use correct initializer macros for struct fb_ops
  fbdev/vfb: Set FBINFO_VIRTFB flag
  fbdev/vfb: Initialize fb_ops with fbdev macros
  fbdev/arcfb: Set FBINFO_VIRTFB flag
  fbdev/arcfb: Use generator macros for deferred I/O
  auxdisplay/cfag12864bfb: Set FBINFO_VIRTFB flag
  auxdisplay/cfag12864bfb: Initialize fb_ops with fbdev macros
  auxdisplay/ht16k33: Set FBINFO_VIRTFB flag
  auxdisplay/ht16k33: Initialize fb_ops with 

[Intel-gfx] [PULL] drm-misc-next

2023-11-23 Thread Maxime Ripard
Hi,

Here's this week drm-misc-next PR.

It's been fairly calm, but there's one big change: the IMG GPU driver is
now merged!

Maxime

drm-misc-next-2023-11-23:
drm-misc-next for 6.8:

UAPI Changes:

Cross-subsystem Changes:

Core Changes:
  - Drop deprecated drm_kms_helper.edid_firmware module parameter

Driver Changes:
  - Convert platform drivers remove callback to return void
  - imagination: Introduction of the Imagination GPU Support
  - rockchip:
- rk3066_hdmi: Convert to atomic
- vop2: Support NV20 and NV30
  - panel:
- elida-kd35t133: PM reworks
- New panels: Powkiddy RK2023
The following changes since commit 3b434a3445fff3149128db0169da864d67057325:

  accel/ivpu: Use threaded IRQ to handle JOB done messages (2023-11-16 13:41:49 
+0100)

are available in the Git repository at:

  git://anongit.freedesktop.org/drm/drm-misc tags/drm-misc-next-2023-11-23

for you to fetch changes up to 815d8b0425ad1164e45953ac3d56a9f6f63792cc:

  drm/imagination: Add driver documentation (2023-11-23 09:01:47 +0100)


drm-misc-next for 6.8:

UAPI Changes:

Cross-subsystem Changes:

Core Changes:
  - Drop deprecated drm_kms_helper.edid_firmware module parameter

Driver Changes:
  - Convert platform drivers remove callback to return void
  - imagination: Introduction of the Imagination GPU Support
  - rockchip:
- rk3066_hdmi: Convert to atomic
- vop2: Support NV20 and NV30
  - panel:
- elida-kd35t133: PM reworks
- New panels: Powkiddy RK2023


Abhinav Singh (1):
  drm/nouveau/fence:: fix warning directly dereferencing a rcu pointer

Arnd Bergmann (1):
  drm/rockchip: rk3066_hdmi: include drm/drm_atomic.h

Chris Morgan (8):
  dt-bindings: display: nv3051d: Update NewVision NV3051D compatibles
  drm/panel: nv3051d: Hold panel in reset for unprepare
  drm/panel: nv3051d: Add Powkiddy RK2023 Panel Support
  drm/panel-elida-kd35t133: trival: update panel size from 5.5 to 3.5
  drm/panel-elida-kd35t133: hold panel in reset for unprepare
  drm/panel-elida-kd35t133: drop drm_connector_set_orientation_from_panel
  drm/panel-elida-kd35t133: Drop shutdown logic
  drm/panel-elida-kd35t133: Drop prepare/unprepare logic

Donald Robson (2):
  drm/gpuvm: Helper to get range of unmap from a remap op.
  drm/imagination: Add GEM and VM related code

Jani Nikula (1):
  drm/edid/firmware: drop drm_kms_helper.edid_firmware backward compat

Jeffrey Hugo (1):
  accel/qaic: Update MAX_ORDER use to be inclusive

Johan Jonker (2):
  drm/rockchip: rk3066_hdmi: Remove useless mode_fixup
  drm/rockchip: rk3066_hdmi: Switch encoder hooks to atomic

Jonas Karlman (1):
  drm/rockchip: vop2: Add NV20 and NV30 support

Kees Cook (1):
  dma-buf: Replace strlcpy() with strscpy()

Luben Tuikov (1):
  drm/print: Handle NULL drm device in __drm_printk()

Matt Coster (1):
  sizes.h: Add entries between SZ_32G and SZ_64T

Richard Acayan (1):
  fbdev/simplefb: Suppress error on missing power domains

Sarah Walker (17):
  dt-bindings: gpu: Add Imagination Technologies PowerVR/IMG GPU
  drm/imagination/uapi: Add PowerVR driver UAPI
  drm/imagination: Add skeleton PowerVR driver
  drm/imagination: Get GPU resources
  drm/imagination: Add GPU register headers
  drm/imagination: Add firmware and MMU related headers
  drm/imagination: Add FWIF headers
  drm/imagination: Add GPU ID parsing and firmware loading
  drm/imagination: Implement power management
  drm/imagination: Implement firmware infrastructure and META FW support
  drm/imagination: Implement MIPS firmware processor and MMU support
  drm/imagination: Implement free list and HWRT create and destroy ioctls
  drm/imagination: Implement context creation/destruction ioctls
  drm/imagination: Implement job submission and scheduling
  drm/imagination: Add firmware trace header
  drm/imagination: Add firmware trace to debugfs
  drm/imagination: Add driver documentation

Tomi Valkeinen (1):
  drm/tilcdc: Fix irq free on unload

Uwe Kleine-König (14):
  drm/bridge: tpd12s015: Drop buggy __exit annotation for remove function
  drm/arcpgu: Convert to platform remove callback returning void
  drm/armada: Convert to platform remove callback returning void
  drm/bridge: cdns-mhdp8546: Improve error reporting in remove callback
  drm/bridge: cdns-mhdp8546: Convert to platform remove callback returning 
void
  drm/bridge: tpd12s015: Convert to platform remove callback returning void
  drm/etnaviv: Convert to platform remove callback returning void
  drm/imx/dcss: Convert to platform remove callback returning void
  drm/imx: lcdc: Convert to platform remove callback returning void
  drm/kmb: Convert to platform remove callback returning void
  drm/mediatek: Convert to 

Re: [Intel-gfx] linux-next: Signed-off-by missing for commit in the drm-misc tree

2023-11-22 Thread Maxime Ripard
Hi Luben,

On Thu, Nov 16, 2023 at 09:27:58AM +0100, Daniel Vetter wrote:
> On Thu, Nov 16, 2023 at 09:11:43AM +0100, Maxime Ripard wrote:
> > On Tue, Nov 14, 2023 at 06:46:21PM -0500, Luben Tuikov wrote:
> > > On 2023-11-13 22:08, Stephen Rothwell wrote:
> > > > BTW, cherry picking commits does not avoid conflicts - in fact it can
> > > > cause conflicts if there are further changes to the files affected by
> > > > the cherry picked commit in either the tree/branch the commit was
> > > > cheery picked from or the destination tree/branch (I have to deal with
> > > > these all the time when merging the drm trees in linux-next).  Much
> > > > better is to cross merge the branches so that the patch only appears
> > > > once or have a shared branches that are merged by any other branch that
> > > > needs the changes.
> > > > 
> > > > I understand that things are not done like this in the drm trees :-(
> > > 
> > > Hi Stephen,
> > > 
> > > Thank you for the clarification--understood. I'll be more careful in the 
> > > future.
> > > Thanks again! :-)
> > 
> > In this case, the best thing to do would indeed have been to ask the
> > drm-misc maintainers to merge drm-misc-fixes into drm-misc-next.
> > 
> > We're doing that all the time, but we're not ubiquitous so you need to
> > ask us :)
> > 
> > Also, dim should have caught that when you pushed the branch. Did you
> > use it?
> 
> Yeah dim must be used, exactly to avoid these issues. Both for applying
> patches (so not git am directly, or cherry-picking from your own
> development branch), and for pushing. The latter is even checked for by
> the server (dim sets a special push flag which is very long and contains a
> very clear warning if you bypass it).
> 
> If dim was used, this would be a bug in the dim script that we need to
> fix.

It would be very useful for you to explain what happened here so we
improve the tooling or doc and can try to make sure it doesn't happen
again

Maxime


signature.asc
Description: PGP signature


Re: [Intel-gfx] [PATCH 0/4] drm/i915: Fix LUT rounding

2023-11-21 Thread Maxime Ripard
On Mon, Nov 20, 2023 at 04:30:53PM +0200, Ville Syrjälä wrote:
> On Fri, Oct 13, 2023 at 04:13:58PM +0300, Ville Syrjala wrote:
> > From: Ville Syrjälä 
> > 
> > The current LUT rounding is generating weird results. Adjust
> > it to follow the OpenGL int<->float conversion rules.
> > 
> > Ville Syrjälä (4):
> >   drm: Fix color LUT rounding
> ^
> I'd like to merge this via drm-intel-next as needs to match
> the rounding done in the readout path in i915.
> 
> Maarten,Maxime,Thomas can I get an ack for that?

Acked-by: Maxime Ripard 

Maxime


signature.asc
Description: PGP signature


[Intel-gfx] [PULL] drm-misc-next

2023-11-17 Thread Maxime Ripard
PM=n

Carl Vanderlip (2):
  accel/qaic: Enable 1 MSI fallback mode
  accel/qaic: Quiet array bounds check on DMA abort message

Christian König (1):
  dma-buf: add dma_fence_timestamp helper

Danilo Krummrich (12):
  drm/sched: implement dynamic job-flow control
  drm/gpuvm: convert WARN() to drm_WARN() variants
  drm/gpuvm: don't always WARN in drm_gpuvm_check_overflow()
  drm/gpuvm: export drm_gpuvm_range_valid()
  drm/nouveau: make use of drm_gpuvm_range_valid()
  drm/gpuvm: add common dma-resv per struct drm_gpuvm
  drm/nouveau: make use of the GPUVM's shared dma-resv
  drm/gpuvm: add drm_gpuvm_flags to drm_gpuvm
  drm/nouveau: separately allocate struct nouveau_uvmm
  drm/gpuvm: reference count drm_gpuvm structures
  drm/gpuvm: add an abstraction for a VM / BO combination
  drm/gpuvm: track/lock/validate external/evicted objects

Dario Binacchi (1):
  drm/panel: nt35510: fix typo

Dmitry Osipenko (1):
  drm/virtio: Fix return value for VIRTGPU_CONTEXT_PARAM_DEBUG_NAME

Emma Anholt (1):
  MAINTAINERS: Drop Emma Anholt from all M lines.

Gurchetan Singh (2):
  drm/virtio: use uint64_t more in virtio_gpu_context_init_ioctl
  drm/uapi: add explicit virtgpu context debug name

Hsin-Yi Wang (3):
  drm/panel-edp: drm/panel-edp: Fix AUO B116XAK01 name and timing
  drm/panel-edp: drm/panel-edp: Fix AUO B116XTN02 name
  drm/panel-edp: drm/panel-edp: Add several generic edp panels

Iago Toral Quiroga (4):
  drm/v3d: update UAPI to match user-space for V3D 7.x
  drm/v3d: fix up register addresses for V3D 7.x
  dt-bindings: gpu: v3d: Add BCM2712's compatible
  drm/v3d: add brcm,2712-v3d as a compatible V3D device

Jacek Lawrynowicz (8):
  accel/ivpu: Simplify MMU SYNC command
  accel/ivpu: Rename VPU to NPU in product strings
  accel/ivpu: Fix compilation with CONFIG_PM=n
  accel/ivpu: Allocate vpu_addr in gem->open() callback
  accel/ivpu: Fix locking in ivpu_bo_remove_all_bos_from_context()
  accel/ivpu: Remove support for uncached buffers
  accel/ivpu: Use GEM shmem helper for all buffers
  accel/ivpu: Use threaded IRQ to handle JOB done messages

Jani Nikula (6):
  drm/edid: split out drm_eld.h from drm_edid.h
  drm/eld: replace uint8_t with u8
  drm/edid: include drm_eld.h only where required
  drm/edid: use a temp variable for sads to drop one level of dereferences
  drm/edid: add helpers to get/set struct cea_sad from/to 3-byte sad
  drm/eld: add helpers to modify the SADs of an ELD

Javier Martinez Canillas (2):
  dt-bindings: display: ssd132x: Remove '-' before compatible enum
  drm/ssd130x: Fix possible uninitialized usage of crtc_state variable

Karol Wachowski (5):
  accel/ivpu: Remove reset from power up sequence
  accel/ivpu: Change test_mode module param to bitmask
  accel/ivpu: Introduce ivpu_ipc_send_receive_active()
  accel/ivpu: Print CMDQ errors after consumer timeout
  accel/ivpu: Make DMA allocations for MMU600 write combined

Krystian Pradzynski (2):
  accel/ivpu: Update FW API
  accel/ivpu/40xx: Allow to change profiling frequency

Kunwu Chan (1):
  drm/atomic-helper: Fix spelling mistake "preceeding" -> "preceding"

Luben Tuikov (4):
  drm/sched: Don't disturb the entity when in RR-mode scheduling
  drm/sched: Qualify drm_sched_wakeup() by drm_sched_entity_is_ready()
  drm/sched: Define pr_fmt() for DRM using pr_*()
  Revert "drm/sched: Define pr_fmt() for DRM using pr_*()"

Marco Pagani (1):
  drm/test: rearrange test entries in Kconfig and Makefile

Matthew Brost (5):
  drm/sched: Add drm_sched_wqueue_* helpers
  drm/sched: Convert drm scheduler to use a work queue rather than kthread
  drm/sched: Split free_job into own work item
  drm/sched: Add drm_sched_start_timeout_unlocked helper
  drm/sched: Add a helper to queue TDR immediately

Maxime Ripard (3):
  drm/tests: Remove slow tests
  drm/todo: Add entry to clean up former seltests suites
  Merge drm/drm-next into drm-misc-next

Maíra Canal (4):
  drm/v3d: wait for all jobs to finish before unregistering
  drm/v3d: Implement show_fdinfo() callback for GPU usage stats
  drm/v3d: Expose the total GPU usage stats on sysfs
  MAINTAINERS: Add Maira to V3D maintainers

Michał Winiarski (1):
  iosys-map: Rename locals used inside macros

Pranjal Ramajor Asha Kanojiya (2):
  accel/qaic: Support MHI QAIC_TIMESYNC channel
  accel/qaic: Support for 0 resize slice execution in BO

Sheng-Liang Pan (1):
  drm/panel-edp: Add AUO B116XTN02, BOE NT116WHM-N21,836X2, NV116WHM-N49 
V8.0

Simon Ser (3):
  drm: extract closefb logic in separate function
  drm: introduce CLOSEFB IOCTL
  drm/doc: describe PATH format for DP MST

Stanislaw Gruszka (9):
  accel/ivpu: Remove unneeded drm_driver declaration
  accel/ivpu/37xx: Pri

Re: [Intel-gfx] linux-next: Signed-off-by missing for commit in the drm-misc tree

2023-11-16 Thread Maxime Ripard
Hi,

On Mon, Nov 13, 2023 at 09:56:32PM -0500, Luben Tuikov wrote:
> On 2023-11-13 21:45, Stephen Rothwell wrote:
> > Hi Luben,
> > 
> > On Mon, 13 Nov 2023 20:32:40 -0500 Luben Tuikov  wrote:
> >>
> >> On 2023-11-13 20:08, Luben Tuikov wrote:
> >>> On 2023-11-13 15:55, Stephen Rothwell wrote:  
>  Hi all,
> 
>  Commit
> 
>    0da611a87021 ("dma-buf: add dma_fence_timestamp helper")
> 
>  is missing a Signed-off-by from its committer.
>   
> >>>
> >>> In order to merge the scheduler changes necessary for the Xe driver, 
> >>> those changes
> >>> were based on drm-tip, which included this change from drm-misc-fixes, 
> >>> but which
> >>> wasn't present in drm-misc-next.
> >>>
> >>> I didn't want to create a merge conflict between drm-misc-next and 
> >>> drm-misc-fixes,
> >>> when pulling that change from drm-misc-next to drm-misc-fixes, so that I 
> >>> can apply  
> >>
> >> ... when pulling that change from from drm-misc-fixes into drm-misc-next, 
> >> so that I can apply...
> >>
> >>> the Xe scheduler changes on top of drm-misc-next.  
> >>
> >> The change in drm-misc-fixes is b83ce9cb4a465b. The latter is contained
> >> in linus-master, and in drm-misc-fixes, while the former is in 
> >> drm-misc-next.
> >> When we merge linus-master/drm-misc-fixes into drm-misc-next, or whichever 
> >> way
> >> it happens, I'd like to avoid a merge conflict, but wanted to expedite the 
> >> changes
> >> for Xe.
> > 
> > None of that is relevant ... if you commit a patch to a tree that will
> > be in the linux kernel tree, you must add your Signed-off-by to the commit.
>
> Noted!
> 
> So I always do this when I do git-am and such, but wasn't sure for this one 
> single cherry-pick whose
> original author was the committer in drm-misc-fixes, but will add my 
> Signed-off-by in those
> rare circumstances.
> 
> Thanks for the clarification!

In order to move forward with this, can you provide your SoB here for
that patch so that we can at least point to it in the drm-misc-next PR?

Maxime


signature.asc
Description: PGP signature


Re: [Intel-gfx] linux-next: Signed-off-by missing for commit in the drm-misc tree

2023-11-16 Thread Maxime Ripard
On Tue, Nov 14, 2023 at 06:46:21PM -0500, Luben Tuikov wrote:
> On 2023-11-13 22:08, Stephen Rothwell wrote:
> > BTW, cherry picking commits does not avoid conflicts - in fact it can
> > cause conflicts if there are further changes to the files affected by
> > the cherry picked commit in either the tree/branch the commit was
> > cheery picked from or the destination tree/branch (I have to deal with
> > these all the time when merging the drm trees in linux-next).  Much
> > better is to cross merge the branches so that the patch only appears
> > once or have a shared branches that are merged by any other branch that
> > needs the changes.
> > 
> > I understand that things are not done like this in the drm trees :-(
> 
> Hi Stephen,
> 
> Thank you for the clarification--understood. I'll be more careful in the 
> future.
> Thanks again! :-)

In this case, the best thing to do would indeed have been to ask the
drm-misc maintainers to merge drm-misc-fixes into drm-misc-next.

We're doing that all the time, but we're not ubiquitous so you need to
ask us :)

Also, dim should have caught that when you pushed the branch. Did you
use it?

Maxime


signature.asc
Description: PGP signature


Re: [Intel-gfx] [PATCH v7 1/6] drm/panelreplay: dpcd register definition for panelreplay

2023-11-06 Thread Maxime Ripard
On Mon, Nov 06, 2023 at 01:01:19PM +, Manna, Animesh wrote:
> 
> 
> > -Original Message-
> > From: Nikula, Jani 
> > Sent: Friday, November 3, 2023 2:55 PM
> > To: Manna, Animesh ; intel-
> > g...@lists.freedesktop.org; Maxime Ripard ; Thomas
> > Zimmermann ; Maarten Lankhorst
> > 
> > Cc: dri-de...@lists.freedesktop.org; Manna, Animesh
> > ; Hogander, Jouni
> > ; Murthy, Arun R 
> > Subject: Re: [PATCH v7 1/6] drm/panelreplay: dpcd register definition for
> > panelreplay
> > 
> > On Wed, 11 Oct 2023, Animesh Manna  wrote:
> > > Add DPCD register definition for discovering, enabling and checking
> > > status of panel replay of the sink.
> > >
> > > Cc: Jouni Högander 
> > > Cc: Arun R Murthy 
> > > Cc: Jani Nikula 
> > > Reviewed-by: Arun R Murthy 
> > > Signed-off-by: Animesh Manna 
> > 
> > Maarten, Maxime, Thomas -
> > 
> > Ack for merging this via drm-intel-next?
> 
> Ping!

Ack

Maxime


signature.asc
Description: PGP signature


Re: [Intel-gfx] [PULL] drm-misc-next

2023-11-06 Thread Maxime Ripard
On Mon, Nov 06, 2023 at 11:37:34AM +0100, Thomas Hellström wrote:
> On 11/6/23 11:20, Maxime Ripard wrote:
> > On Mon, Nov 06, 2023 at 11:01:51AM +0100, Thomas Hellström wrote:
> > > Hi, David.
> > > 
> > > On 11/3/23 17:37, David Edelsohn wrote:
> > > > Dual-license drm_gpuvm to GPL-2.0 OR MIT.
> > > > diff --git a/drivers/gpu/drm/drm_gpuvm.c b/drivers/gpu/drm/drm_gpuvm.c
> > > > index 02ce6baacdad..08c088319652 100644 ---
> > > > a/drivers/gpu/drm/drm_gpuvm.c 
> > > > <https://cgit.freedesktop.org/drm/drm-misc/tree/drivers/gpu/drm/drm_gpuvm.c?id=6f2eeef4a0aa9791bbba9d353641a6e067bb86c1>
> > > > +++ b/drivers/gpu/drm/drm_gpuvm.c 
> > > > <https://cgit.freedesktop.org/drm/drm-misc/tree/drivers/gpu/drm/drm_gpuvm.c?id=f7749a549b4f4db0c02e6b3d3800ea400dd76c12>
> > > > @@ -1,4 +1,4 @@
> > > > -// SPDX-License-Identifier: GPL-2.0-only
> > > > +// SPDX-License-Identifier: GPL-2.0 OR MIT
> > > > /*
> > > > * Copyright (c) 2022 Red Hat.
> > > > *
> > > > The above SPDX License Identifier change is incorrect and no longer
> > > > valid. The change misunderstood the syntax of SPDX license identifiers
> > > > and boolean operations. GPL-2.0-only is the name of the license and 
> > > > means
> > > > GPL 2.0 only, as opposed to GPL 2.0 or later. The "only" does not
> > > > refer to restrictions on other licenses in the identifier and should not
> > > > have been
> > > > removed. The hyphens designated that the name was a single unit.
> > > > The SPDX License Identifier boolean operators, such as OR, are a
> > > > separate layer
> > > > of syntax.
> > > > The SPDX License Identifier should be
> > > > GPL-2.0-only OR MIT
> > > > Thanks, David
> > > The author has acked the change / relicensing, which is also described in
> > > the commit title so could you please elaborate why you think it is not
> > > valid?
> > I think their point isn't so much about the license itself but rather
> > the SPDX syntax to express it.
> > 
> > Maxime
> 
> Hm. There are a pretty large number of these in drm with the same syntax:
> 
> SPDX-License-Identifier: GPL-2.0 OR MIT
> 
> So I read it as whe shouldn't have change "Licence A" to "Licence B OR
> C" but instead should have changed it to "Licence A OR C", hence the
> *change* (rather than the syntax) would no longer be valid.
> 
> Perhaps I have had too little coffee this morning.
> 
> I'd appreciate if David could clarify.

Either way, one of the issue is that GPL-2.0 was deprecated in favour of
GPL-2.0-only

https://spdx.org/licenses/GPL-2.0.html

So you effectively changed the preferred syntax to the deprecated one in
the process of adding the new license.

I think that's what David was saying, but there might be something else :)

Maxime


signature.asc
Description: PGP signature


Re: [Intel-gfx] (subset) [PATCH 1/7] drm: Do not round to megabytes for greater than 1MiB sizes in fdinfo stats

2023-11-06 Thread Maxime Ripard
On Wed, 27 Sep 2023 14:38:37 +0100, Tvrtko Ursulin wrote:
> It is better not to lose precision and not revert to 1 MiB size
> granularity for every size greater than 1 MiB.
> 
> Sizes in KiB should not be so troublesome to read (and in fact machine
> parsing is I expect the norm here), they align with other api like
> /proc/meminfo, and they allow writing tests for the interface without
> having to embed drm.ko implementation knowledge into them. (Like knowing
> that minimum buffer size one can use for successful verification has to be
> 1MiB aligned, and on top account for any pre-existing memory utilisation
> outside of driver's control.)
> 
> [...]

Applied to drm/drm-misc (drm-misc-next).

Thanks!
Maxime



Re: [Intel-gfx] [PULL] drm-misc-next

2023-11-06 Thread Maxime Ripard
On Mon, Nov 06, 2023 at 11:01:51AM +0100, Thomas Hellström wrote:
> Hi, David.
> 
> On 11/3/23 17:37, David Edelsohn wrote:
> > Dual-license drm_gpuvm to GPL-2.0 OR MIT.
> > diff --git a/drivers/gpu/drm/drm_gpuvm.c b/drivers/gpu/drm/drm_gpuvm.c
> > index 02ce6baacdad..08c088319652 100644 ---
> > a/drivers/gpu/drm/drm_gpuvm.c 
> > 
> > +++ b/drivers/gpu/drm/drm_gpuvm.c 
> > 
> > @@ -1,4 +1,4 @@
> > -// SPDX-License-Identifier: GPL-2.0-only
> > +// SPDX-License-Identifier: GPL-2.0 OR MIT
> > /*
> > * Copyright (c) 2022 Red Hat.
> > *
> > The above SPDX License Identifier change is incorrect and no longer
> > valid. The change misunderstood the syntax of SPDX license identifiers
> > and boolean operations. GPL-2.0-only is the name of the license and means
> > GPL 2.0 only, as opposed to GPL 2.0 or later. The "only" does not
> > refer to restrictions on other licenses in the identifier and should not
> > have been
> > removed. The hyphens designated that the name was a single unit.
> > The SPDX License Identifier boolean operators, such as OR, are a
> > separate layer
> > of syntax.
> > The SPDX License Identifier should be
> > GPL-2.0-only OR MIT
> > Thanks, David
> 
> The author has acked the change / relicensing, which is also described in
> the commit title so could you please elaborate why you think it is not
> valid?

I think their point isn't so much about the license itself but rather
the SPDX syntax to express it.

Maxime


signature.asc
Description: PGP signature


Re: [Intel-gfx] [PATCH v4 02/30] drm/dp_mst: Fix fractional DSC bpp handling

2023-11-06 Thread Maxime Ripard
On Wed, Nov 01, 2023 at 02:59:50PM +0200, Jani Nikula wrote:
> On Tue, 31 Oct 2023, Imre Deak  wrote:
> > On Mon, Oct 30, 2023 at 05:58:15PM +0200, Imre Deak wrote:
> > Hi Lyude, AMD folks et al,
> >
> > could you ack patches 2-9 in this patchset if they are ok and it's ok to
> > merge them via the i915 tree?
> 
> Need acks from drm-misc maintainers too!
> 
> Cc: Maxime, Thomas, Maarten

Acked-by: Maxime Ripard 

Maxime


signature.asc
Description: PGP signature


Re: [Intel-gfx] [PATCH] MAINTAINERS: drm/ci: add entries for xfail files

2023-10-26 Thread Maxime Ripard
On Tue, 19 Sep 2023 15:22:49 -0300, Helen Koike wrote:
> DRM CI keeps track of which tests are failing, flaking or being skipped
> by the ci in the expectations files. Add entries for those files to the
> corresponding driver maintainer, so they can be notified when they
> change.
> 
> 

Applied to drm/drm-misc (drm-misc-next).

Thanks!
Maxime



Re: [Intel-gfx] [PATCH v2] MAINTAINERS: Update drm-misc entry to match all drivers

2023-09-28 Thread Maxime Ripard
Hi,

On Thu, Sep 21, 2023 at 12:57:43PM +0200, Maxime Ripard wrote:
> We've had a number of times when a patch slipped through and we couldn't
> pick them up either because our MAINTAINERS entry only covers the
> framework and thus we weren't Cc'd.
> 
> Let's take another approach where we match everything, and remove all
> the drivers that are not maintained through drm-misc.
> 
> Acked-by: Jani Nikula 
> Signed-off-by: Maxime Ripard 

Applied with Dave's Acked-by given on IRC.

This was conflicting with
https://lore.kernel.org/r/20230925154929.1.I3287e895ce8e68d41b458494a49a1b5ec5c71013@changeid

So I removed the imx exclusion from that list while applying.

Maxime


signature.asc
Description: PGP signature


Re: [Intel-gfx] [PATCH 1/8] drm/display/dp: Add helper function to get DSC bpp prescision

2023-09-22 Thread Maxime Ripard
On Thu, Sep 21, 2023 at 10:41:43AM +0300, Jani Nikula wrote:
> On Wed, 13 Sep 2023, Mitul Golani  
> wrote:
> > From: Ankit Nautiyal 
> >
> > Add helper to get the DSC bits_per_pixel precision for the DP sink.
> >
> > Signed-off-by: Ankit Nautiyal 
> 
> Maarten, Maxime, Thomas, ack for merging this via drm-intel please?

That's fine by me :)

Maxime


signature.asc
Description: PGP signature


[Intel-gfx] [PATCH v2] MAINTAINERS: Update drm-misc entry to match all drivers

2023-09-21 Thread Maxime Ripard
We've had a number of times when a patch slipped through and we couldn't
pick them up either because our MAINTAINERS entry only covers the
framework and thus we weren't Cc'd.

Let's take another approach where we match everything, and remove all
the drivers that are not maintained through drm-misc.

Acked-by: Jani Nikula 
Signed-off-by: Maxime Ripard 

---

Cc: Alex Deucher 
Cc: Christian König 
Cc: "Pan, Xinhui" 
Cc: Russell King 
Cc: Lucas Stach 
Cc: Christian Gmeiner 
Cc: Inki Dae 
Cc: Seung-Woo Kim 
Cc: Kyungmin Park 
Cc: Jani Nikula 
Cc: Joonas Lahtinen 
Cc: Rodrigo Vivi 
Cc: Tvrtko Ursulin 
Cc: Philipp Zabel 
Cc: Laurentiu Palcu 
Cc: Anitha Chrisanthus 
Cc: Edmund Dea 
Cc: Chun-Kuang Hu 
Cc: Rob Clark 
Cc: Abhinav Kumar 
Cc: Dmitry Baryshkov 
Cc: Sean Paul 
Cc: Marijn Suijten 
Cc: Ben Skeggs 
Cc: Karol Herbst 
Cc: Lyude Paul 
Cc: Laurent Pinchart 
Cc: Kieran Bingham 
Cc: Thierry Reding 
Cc: Mikko Perttunen 
Cc: dri-de...@lists.freedesktop.org
Cc: amd-...@lists.freedesktop.org
Cc: etna...@lists.freedesktop.org
Cc: intel-gfx@lists.freedesktop.org
Cc: nouv...@lists.freedesktop.org
Cc: linux-renesas-...@vger.kernel.org
Cc: linux-te...@vger.kernel.org

Changes from v1:
- Remove ingenic and gma500 from the excluded list
---
 MAINTAINERS | 21 ++---
 1 file changed, 18 insertions(+), 3 deletions(-)

diff --git a/MAINTAINERS b/MAINTAINERS
index 90f13281d297..1012402dada5 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -6860,12 +6860,27 @@ M:  Thomas Zimmermann 
 S: Maintained
 W: https://01.org/linuxgraphics/gfx-docs/maintainer-tools/drm-misc.html
 T: git git://anongit.freedesktop.org/drm/drm-misc
+F: Documentation/devicetree/bindings/display/
+F: Documentation/devicetree/bindings/gpu/
 F: Documentation/gpu/
-F: drivers/gpu/drm/*
+F: drivers/gpu/drm/
 F: drivers/gpu/vga/
-F: include/drm/drm*
+F: include/drm/drm
 F: include/linux/vga*
-F: include/uapi/drm/drm*
+F: include/uapi/drm/
+X: drivers/gpu/drm/amd/
+X: drivers/gpu/drm/armada/
+X: drivers/gpu/drm/etnaviv/
+X: drivers/gpu/drm/exynos/
+X: drivers/gpu/drm/i915/
+X: drivers/gpu/drm/imx/
+X: drivers/gpu/drm/kmb/
+X: drivers/gpu/drm/mediatek/
+X: drivers/gpu/drm/msm/
+X: drivers/gpu/drm/nouveau/
+X: drivers/gpu/drm/radeon/
+X: drivers/gpu/drm/renesas/
+X: drivers/gpu/drm/tegra/
 
 DRM DRIVERS FOR ALLWINNER A10
 M:     Maxime Ripard 
-- 
2.41.0



Re: [Intel-gfx] [PATCH] MAINTAINERS: drm/ci: add entries for xfail files

2023-09-20 Thread Maxime Ripard
Hi,

On Tue, Sep 19, 2023 at 03:22:49PM -0300, Helen Koike wrote:
> DRM CI keeps track of which tests are failing, flaking or being skipped
> by the ci in the expectations files. Add entries for those files to the
> corresponding driver maintainer, so they can be notified when they
> change.
> 
> Signed-off-by: Helen Koike 

Thanks for sending this

Acked-by: Maxime Ripard 

Maxime


signature.asc
Description: PGP signature


[Intel-gfx] [PULL] drm-misc-fixes

2023-09-07 Thread Maxime Ripard
Hi,

Here's this week drm-misc-fixes PR

Maxime

drm-misc-fixes-2023-09-07:
One doc fix for drm/connector, one fix for amdgpu for an crash when
VRAM usage is high, and one fix in gm12u320 to fix the timeout units in
the code
The following changes since commit f9e96bf1905479f18e83a3a4c314a8dfa56ede2c:

  drm/vmwgfx: Fix possible invalid drm gem put calls (2023-08-23 13:20:04 -0400)

are available in the Git repository at:

  git://anongit.freedesktop.org/drm/drm-misc tags/drm-misc-fixes-2023-09-07

for you to fetch changes up to 7583028d359db3cd0072badcc576b4f9455fd27a:

  drm: gm12u320: Fix the timeout usage for usb_bulk_msg() (2023-09-04 10:00:57 
+0200)


One doc fix for drm/connector, one fix for amdgpu for an crash when
VRAM usage is high, and one fix in gm12u320 to fix the timeout units in
the code


Jinjie Ruan (1):
  drm: gm12u320: Fix the timeout usage for usb_bulk_msg()

Lee Jones (1):
  drm/drm_connector: Provide short description of param 
'supported_colorspaces'

Simon Pilkington (1):
  drm/amd: Make fence wait in suballocator uninterruptible

 drivers/gpu/drm/amd/amdgpu/amdgpu_sa.c |  2 +-
 drivers/gpu/drm/drm_connector.c|  2 ++
 drivers/gpu/drm/tiny/gm12u320.c| 10 +-
 3 files changed, 8 insertions(+), 6 deletions(-)


signature.asc
Description: PGP signature


Re: [Intel-gfx] [PATCH v3 4/5] drm/vc4: add trailing newlines to drm_dbg msgs

2023-09-07 Thread Maxime Ripard
On Wed, 6 Sep 2023 13:02:22 -0600, Jim Cromie wrote:
> By at least strong convention, a print-buffer's trailing newline says
> "message complete, send it".  The exception (no TNL, followed by a call
> to pr_cont) proves the general rule.
> 
> Most DRM.debug calls already comport with this: 207 DRM_DEV_DEBUG,
> 
> [ ... ]

Acked-by: Maxime Ripard 

Thanks!
Maxime


Re: [Intel-gfx] [PATCH v3 1/5] drm/connector: add trailing newlines to drm_dbg msgs

2023-09-07 Thread Maxime Ripard
On Wed, Sep 06, 2023 at 01:02:19PM -0600, Jim Cromie wrote:
> By at least strong convention, a print-buffer's trailing newline says
> "message complete, send it".  The exception (no TNL, followed by a call
> to pr_cont) proves the general rule.
> 
> Most DRM.debug calls already comport with this: 207 DRM_DEV_DEBUG,
> 1288 drm_dbg.  Clean up the remainders, in maintainer sized chunks.
> 
> No functional changes.
> 
> Signed-off-by: Jim Cromie 
> ---
>  drivers/gpu/drm/drm_connector.c | 4 +++-
>  1 file changed, 3 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/gpu/drm/drm_connector.c b/drivers/gpu/drm/drm_connector.c
> index f28725736237..14020585bdc0 100644
> --- a/drivers/gpu/drm/drm_connector.c
> +++ b/drivers/gpu/drm/drm_connector.c
> @@ -2925,7 +2925,9 @@ int drm_mode_getconnector(struct drm_device *dev, void 
> *data,
>dev->mode_config.max_width,
>
> dev->mode_config.max_height);
>   else
> - drm_dbg_kms(dev, "User-space requested a forced probe 
> on [CONNECTOR:%d:%s] but is not the DRM master, demoting to read-only probe",
> + drm_dbg_kms(dev,
> + "User-space requested a forced probe on 
> [CONNECTOR:%d:%s] "
> + "but is not the DRM master, demoting to 
> read-only probe\n",
>   connector->base.id, connector->name);

I'm fine with the general idea behind this patch, but we shouldn't break
the message itself.

See 
https://www.kernel.org/doc/html/latest/process/coding-style.html#breaking-long-lines-and-strings

Maxime


signature.asc
Description: PGP signature


Re: [Intel-gfx] [PATCH 0/6] drm, cec and edid updates

2023-09-01 Thread Maxime Ripard
On Thu, Aug 31, 2023 at 09:51:24PM +0300, Jani Nikula wrote:
> On Thu, 24 Aug 2023, Jani Nikula  wrote:
> > Avoid accessing the raw edid directly. Pre-parse the source physical
> > address during normal EDID parsing and use that for CEC.
> >
> > Jani Nikula (6):
> >   drm/edid: add drm_edid_is_digital()
> >   drm/i915/display: use drm_edid_is_digital()
> >   drm/edid: parse source physical address
> >   drm/cec: add drm_dp_cec_attach() as the non-edid version of set edid
> >   drm/i915/cec: switch to setting physical address directly
> 
> Maarten, Maxime, Thomas, ack for merging patches 1, 3 and 4 via via
> drm-intel?

Acked-by: Maxime Ripard 

Maxime


signature.asc
Description: PGP signature


Re: [Intel-gfx] [PATCH 1/2] drm/display/dp: Assume 8 bpc support when DSC is supported

2023-08-29 Thread Maxime Ripard
On Tue, Aug 29, 2023 at 11:44:10AM +0300, Jani Nikula wrote:
> On Thu, 24 Aug 2023, Ankit Nautiyal  wrote:
> > As per DP v1.4, a DP DSC Sink device shall support 8bpc in DPCD 6Ah.
> > Apparently some panels that do support DSC, are not setting the bit for
> > 8bpc.
> >
> > So always assume 8bpc support by DSC decoder, when DSC is claimed to be
> > supported.
> 
> Maarten, Maxime, Thomas, ack for merging this via drm-intel?

That's fine by me

Maxime


signature.asc
Description: PGP signature


[Intel-gfx] [PULL] drm-misc-fixes

2023-08-24 Thread Maxime Ripard
Hi,

Here's this week drm-misc-fixes PR

Maxime

drm-misc-fixes-2023-08-24:
A samsung-dsim initialization fix, a devfreq fix for panfrost, a DP DSC
define fix, a recursive lock fix for dma-buf, a shader validation fix
and a reference counting fix for vmwgfx
The following changes since commit 50b6f2c8297793f7f3315623db78dcff85158e96:

  Revert "drm/edid: Fix csync detailed mode parsing" (2023-08-17 14:39:12 +0300)

are available in the Git repository at:

  git://anongit.freedesktop.org/drm/drm-misc tags/drm-misc-fixes-2023-08-24

for you to fetch changes up to f9e96bf1905479f18e83a3a4c314a8dfa56ede2c:

  drm/vmwgfx: Fix possible invalid drm gem put calls (2023-08-23 13:20:04 -0400)


A samsung-dsim initialization fix, a devfreq fix for panfrost, a DP DSC
define fix, a recursive lock fix for dma-buf, a shader validation fix
and a reference counting fix for vmwgfx


Ankit Nautiyal (1):
  drm/display/dp: Fix the DP DSC Receiver cap size

David Michael (1):
  drm/panfrost: Skip speed binning on EOPNOTSUPP

Frieder Schrempf (1):
  drm: bridge: samsung-dsim: Fix init during host transfer

Rob Clark (1):
  dma-buf/sw_sync: Avoid recursive lock during fence signal

Zack Rusin (2):
  drm/vmwgfx: Fix shader stage validation
  drm/vmwgfx: Fix possible invalid drm gem put calls

 drivers/dma-buf/sw_sync.c   | 18 +++
 drivers/gpu/drm/bridge/samsung-dsim.c   | 27 +-
 drivers/gpu/drm/panfrost/panfrost_devfreq.c |  2 +-
 drivers/gpu/drm/vmwgfx/vmwgfx_bo.c  |  6 ++---
 drivers/gpu/drm/vmwgfx/vmwgfx_bo.h  |  8 +++
 drivers/gpu/drm/vmwgfx/vmwgfx_drv.h | 12 ++
 drivers/gpu/drm/vmwgfx/vmwgfx_execbuf.c | 35 +++--
 drivers/gpu/drm/vmwgfx/vmwgfx_kms.c |  6 ++---
 drivers/gpu/drm/vmwgfx/vmwgfx_overlay.c |  3 +--
 drivers/gpu/drm/vmwgfx/vmwgfx_shader.c  |  3 +--
 include/drm/display/drm_dp.h|  2 +-
 11 files changed, 67 insertions(+), 55 deletions(-)


signature.asc
Description: PGP signature


Re: [Intel-gfx] [REGRESSION] HDMI connector detection broken in 6.3 on Intel(R) Celeron(R) N3060 integrated graphics

2023-08-21 Thread Maxime Ripard
On Tue, Aug 15, 2023 at 11:12:46AM +0300, Jani Nikula wrote:
> On Mon, 14 Aug 2023, Imre Deak  wrote:
> > On Sun, Aug 13, 2023 at 03:41:30PM +0200, Linux regression tracking 
> > (Thorsten Leemhuis) wrote:
> > Hi,
> >
> >> On 11.08.23 20:10, Mikhail Rudenko wrote:
> >> > On 2023-08-11 at 08:45 +02, Thorsten Leemhuis 
> >> >  wrote:
> >> >> On 10.08.23 21:33, Mikhail Rudenko wrote:
> >> >>> The following is a copy an issue I posted to drm/i915 gitlab [1] two
> >> >>> months ago. I repost it to the mailing lists in hope that it will help
> >> >>> the right people pay attention to it.
> >> >>
> >> >> Thx for your report. Wonder why Dmitry (who authored a4e771729a51) or
> >> >> Thomas (who committed it) it didn't look into this, but maybe the i915
> >> >> devs didn't forward the report to them.
> >> 
> >> For the record: they did, and Jani mentioned already. Sorry, should have
> >> phrased this differently.
> >> 
> >> >> Let's see if these mails help. Just wondering: does reverting
> >> >> a4e771729a51 from 6.5-rc5 or drm-tip help as well?
> >> > 
> >> > I've redone my tests with 6.5-rc5, and here are the results:
> >> > (1) 6.5-rc5 -> still affected
> >> > (2) 6.5-rc5 + revert a4e771729a51 -> not affected
> >> > (3) 6.5-rc5 + two patches [1][2] suggested on i915 gitlab by @ideak -> 
> >> > not affected (!)
> >> > 
> >> > Should we somehow tell regzbot about (3)?
> >> 
> >> That's good to know, thx. But the more important things are:
> >> 
> >> * When will those be merged? They are not yet in next yet afaics, so it
> >> might take some time to mainline them, especially at this point of the
> >> devel cycle. Imre, could you try to prod the right people so that these
> >> are ideally upstreamed rather sooner than later, as they fix a regression?
> >
> > I think the patches ([1] and [2]) could be merged via the drm-intel-next
> > (drm-intel-fixes) tree Cc'ing also stable. Jani, is this ok?
> 
> It's fine by me, but need drm-misc maintainer ack to merge [1] via
> drm-intel.

That's fine for me

Maxime


signature.asc
Description: PGP signature


[Intel-gfx] [PULL] drm-misc-fixes

2023-08-17 Thread Maxime Ripard
Hi,

Here's this week drm-misc-fixes PR

Maxime

drm-misc-fixes-2023-08-17:
One EPROBE_DEFER handling fix for the JDI LT070ME05000, a timing fix for
the AUO G121EAN01 panel, an integer overflow and a memory leak fixes for
the qaic accel, a use-after-free fix for nouveau and a revert for an
alleged fix in EDID parsing.
The following changes since commit 07dd476f6116966cb2006e25fdcf48f0715115ff:

  drm/shmem-helper: Reset vma->vm_ops before calling dma_buf_mmap() (2023-08-10 
08:29:14 +0200)

are available in the Git repository at:

  git://anongit.freedesktop.org/drm/drm-misc tags/drm-misc-fixes-2023-08-17

for you to fetch changes up to 50b6f2c8297793f7f3315623db78dcff85158e96:

  Revert "drm/edid: Fix csync detailed mode parsing" (2023-08-17 14:39:12 +0300)


One EPROBE_DEFER handling fix for the JDI LT070ME05000, a timing fix for
the AUO G121EAN01 panel, an integer overflow and a memory leak fixes for
the qaic accel, a use-after-free fix for nouveau and a revert for an
alleged fix in EDID parsing.


Dan Carpenter (1):
  accel/qaic: Clean up integer overflow checking in map_user_pages()

David Heidelberg (1):
  drm/panel: JDI LT070ME05000 simplify with dev_err_probe()

Jani Nikula (1):
  Revert "drm/edid: Fix csync detailed mode parsing"

Karol Herbst (1):
  drm/nouveau/disp: fix use-after-free in error handling of 
nouveau_connector_create

Luca Ceresoli (1):
  drm/panel: simple: Fix AUO G121EAN01 panel timings according to the docs

Pranjal Ramajor Asha Kanojiya (1):
  accel/qaic: Fix slicing memory leak

 drivers/accel/qaic/qaic_control.c  | 26 +--
 drivers/accel/qaic/qaic_data.c |  1 +
 drivers/gpu/drm/drm_edid.c | 29 ++---
 drivers/gpu/drm/nouveau/nouveau_connector.c| 11 +---
 drivers/gpu/drm/panel/panel-jdi-lt070me05000.c | 36 ++
 drivers/gpu/drm/panel/panel-simple.c   | 24 -
 include/drm/drm_edid.h | 12 +++--
 7 files changed, 63 insertions(+), 76 deletions(-)


signature.asc
Description: PGP signature


Re: [Intel-gfx] [PATCH] video/hdmi: convert *_infoframe_init() functions to void

2023-08-10 Thread Maxime Ripard
Hi,

On Tue, Aug 08, 2023 at 11:02:45AM -0700, Nikita Zhandarovich wrote:
> Four hdmi_*_infoframe_init() functions that initialize different
> types of hdmi infoframes only return the default 0 value, contrary to
> their descriptions. Yet these functions are still unnecessarily checked
> against possible errors in case of failure.
> 
> Remove redundant error checks in calls to following functions:
> - hdmi_spd_infoframe_init
> - hdmi_audio_infoframe_init
> - hdmi_vendor_infoframe_init
> - hdmi_drm_infoframe_init
> Also, convert these functions to 'void' and fix their descriptions.

I'm not sure what value it actually adds. None of them return any
errors, but very well might if we started to be a bit serious about it.

Since the error handling is already there, then I'd rather leave it
there.

> Fixes: 2c676f378edb ("[media] hdmi: added unpack and logging functions for 
> InfoFrames")

I'm confused about that part. What does it fix exactly?

Maxime


signature.asc
Description: PGP signature


[Intel-gfx] [PULL] drm-misc-fixes

2023-08-10 Thread Maxime Ripard
Hi,

Here's this week drm-misc-fixes PR

Maxime

drm-misc-fixes-2023-08-10:
Multiple fixes for nouveau around memory safety and DisplayPort, one fix
to reduce the log level of rockchip, a power state fix for the it6505
bridge, a timing fix for the lt9611 bridge, a cache maintenance fix for
ivpu and one to reset vma->vm_ops on mmap for shmem-helper.
The following changes since commit c71b7aa8619a0c9700132d0733e33999fb614339:

  drm/panel: samsung-s6d7aa0: Add MODULE_DEVICE_TABLE (2023-08-02 10:56:50 
+0200)

are available in the Git repository at:

  git://anongit.freedesktop.org/drm/drm-misc tags/drm-misc-fixes-2023-08-10

for you to fetch changes up to 07dd476f6116966cb2006e25fdcf48f0715115ff:

  drm/shmem-helper: Reset vma->vm_ops before calling dma_buf_mmap() (2023-08-10 
08:29:14 +0200)


Multiple fixes for nouveau around memory safety and DisplayPort, one fix
to reduce the log level of rockchip, a power state fix for the it6505
bridge, a timing fix for the lt9611 bridge, a cache maintenance fix for
ivpu and one to reset vma->vm_ops on mmap for shmem-helper.


Arnd Bergmann (1):
  drm/nouveau: remove unused tu102_gr_load() function

Boris Brezillon (1):
  drm/shmem-helper: Reset vma->vm_ops before calling dma_buf_mmap()

Daniel Stone (1):
  drm/rockchip: Don't spam logs in atomic check

Karol Herbst (2):
  drm/nouveau/gr: enable memory loads on helper invocation on all channels
  drm/nouveau/disp: Revert a NULL check inside nouveau_connector_get_modes

Karol Wachowski (1):
  accel/ivpu: Add set_pages_array_wc/uc for internal buffers

Lyude Paul (1):
  drm/nouveau/nvkm/dp: Add workaround to fix DP 1.3+ DPCD issues

Neil Armstrong (1):
  Revert "drm/bridge: lt9611: Do not generate HFP/HBP/HSA and EOT packet"

Pin-yen Lin (1):
  drm/bridge: it6505: Check power state with it6505->powered in IRQ handler

 drivers/accel/ivpu/ivpu_gem.c  |  8 
 drivers/gpu/drm/bridge/ite-it6505.c|  4 +-
 drivers/gpu/drm/bridge/lontium-lt9611.c|  4 +-
 drivers/gpu/drm/drm_gem_shmem_helper.c |  6 +++
 drivers/gpu/drm/nouveau/nouveau_connector.c|  2 +-
 drivers/gpu/drm/nouveau/nvkm/engine/disp/dp.c  | 48 +-
 drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgf100.h  |  1 +
 drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgk104.c  |  4 +-
 drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgk110.c  | 10 +
 drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgk110b.c |  1 +
 drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgk208.c  |  1 +
 drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgm107.c  |  1 +
 drivers/gpu/drm/nouveau/nvkm/engine/gr/tu102.c | 13 --
 drivers/gpu/drm/rockchip/rockchip_drm_vop.c| 17 
 14 files changed, 92 insertions(+), 28 deletions(-)


signature.asc
Description: PGP signature


[Intel-gfx] [PULL] drm-misc-fixes

2023-08-03 Thread Maxime Ripard
Hi,

Here's this week drm-misc-fixes PR

Maxime

The following changes since commit 39b1320e5dc2b707dfb5c25b0298ce9d4fc05aea:

  drm/fb-helper: Remove unused inline function drm_fb_helper_defio_init() 
(2023-07-25 20:38:37 +0200)

are available in the Git repository at:

  ssh://git.freedesktop.org/git/drm/drm-misc tags/drm-misc-fixes-2023-08-03

for you to fetch changes up to c71b7aa8619a0c9700132d0733e33999fb614339:

  drm/panel: samsung-s6d7aa0: Add MODULE_DEVICE_TABLE (2023-08-02 10:56:50 
+0200)


A NULL pointer dereference fix for TTM, a timings fix for imx/ipuv3 and
the addition of a MUDULE_DEVICE_TABLE for the samsung-s6d7aa0 panel.


Alexander Stein (1):
  drm/imx/ipuv3: Fix front porch adjustment upon hactive aligning

Guchun Chen (1):
  drm/ttm: check null pointer before accessing when swapping

Nikita Travkin (1):
  drm/panel: samsung-s6d7aa0: Add MODULE_DEVICE_TABLE

 drivers/gpu/drm/imx/ipuv3/ipuv3-crtc.c| 2 +-
 drivers/gpu/drm/panel/panel-samsung-s6d7aa0.c | 1 +
 drivers/gpu/drm/ttm/ttm_bo.c  | 3 ++-
 3 files changed, 4 insertions(+), 2 deletions(-)


signature.asc
Description: PGP signature


[Intel-gfx] [PULL] drm-misc-fixes

2023-07-27 Thread Maxime Ripard
Hi,

Here's this week drm-misc-fixes PR

Maxime

drm-misc-fixes-2023-07-27:
A single patch to remove an unused function.
The following changes since commit ea293f823a8805735d9e00124df81a8f448ed1ae:

  drm/nouveau/kms/nv50-: init hpd_irq_lock for PIOR DP (2023-07-19 11:08:47 
+0200)

are available in the Git repository at:

  git://anongit.freedesktop.org/drm/drm-misc tags/drm-misc-fixes-2023-07-27

for you to fetch changes up to 39b1320e5dc2b707dfb5c25b0298ce9d4fc05aea:

  drm/fb-helper: Remove unused inline function drm_fb_helper_defio_init() 
(2023-07-25 20:38:37 +0200)


A single patch to remove an unused function.


YueHaibing (1):
  drm/fb-helper: Remove unused inline function drm_fb_helper_defio_init()

 include/drm/drm_fb_helper.h | 5 -
 1 file changed, 5 deletions(-)


signature.asc
Description: PGP signature


[Intel-gfx] [PULL] drm-misc-next

2023-07-21 Thread Maxime Ripard
Hi,

Here's this week drm-misc-next PR

Thanks!
Maxime

The following changes since commit 36672dda2eb715af99e9abbcdc400d46598b691c:

  drm/loongson: Remove a useless check in cursor_plane_atomic_async_check() 
(2023-07-13 01:24:42 +0800)

are available in the Git repository at:

  ssh://git.freedesktop.org/git/drm/drm-misc tags/drm-misc-next-2023-07-21

for you to fetch changes up to d281eeaa4de2636ff0c8e6ae387bb07b50e5fcbb:

  drm: adv7511: Fix low refresh rate register for ADV7533/5 (2023-07-21 
13:37:18 +0200)


drm-misc-next for 6.6:

UAPI Changes:
  - syncobj: New DRM_IOCTL_SYNCOBJ_EVENTFD ioctl

Cross-subsystem Changes:
  - Converge to use of_device_uevent()

Core Changes:
  - GPU VA Manager
  - improvements to make it clearer that drm_minor_type is uAPI

Driver Changes:
  - ssd130x: Improve intermediate buffer size computation
  - bridges:
- adv7511: Fix low refresh rate
- anx7625: Switch to macros instead of hardcoded values
  - panel:
- ld9040: Backlight support, magic improved


Bogdan Togorean (1):
  drm: adv7511: Fix low refresh rate register for ADV7533/5

Chen-Yu Tsai (2):
  drm/bridge: anx7625: Use common macros for DP power sequencing commands
  drm/bridge: anx7625: Use common macros for HDCP capabilities

Danilo Krummrich (2):
  drm: manager to keep track of GPUs VA mappings
  drm: debugfs: provide infrastructure to dump a DRM GPU VA space

Javier Martinez Canillas (1):
  drm/ssd130x: Change pixel format used to compute the buffer size

Marek Vasut (1):
  drm/panel: simple: Drop prepared_time

Miquel Raynal (2):
  of: module: Export of_device_uevent()
  gpu: host1x: Stop open-coding of_device_uevent()

Paul Cercueil (2):
  drm/panel: ld9040: Use better magic values
  drm/panel: ld9040: Register a backlight device

Rob Herring (2):
  gpu/host1x: Explicitly include correct DT includes
  drm: Explicitly include correct DT includes

Simon Ser (3):
  drm/drv: use enum drm_minor_type when appropriate
  drm/file: use explicit values for enum drm_minor_type
  drm/syncobj: add IOCTL to register an eventfd

Steven Price (2):
  drm: manager: Fix printk format for size_t
  drm: debugfs: Silence warning from cast

 Documentation/gpu/drm-mm.rst   |   36 +
 drivers/gpu/drm/Makefile   |1 +
 drivers/gpu/drm/arm/display/komeda/komeda_dev.c|2 +-
 drivers/gpu/drm/arm/malidp_drv.c   |1 +
 drivers/gpu/drm/bridge/adv7511/adv7511_cec.c   |1 -
 drivers/gpu/drm/bridge/adv7511/adv7511_drv.c   |   11 +-
 drivers/gpu/drm/bridge/analogix/anx7625.c  |   12 +-
 drivers/gpu/drm/bridge/cadence/cdns-dsi-core.c |3 +-
 .../gpu/drm/bridge/cadence/cdns-mhdp8546-core.c|1 -
 drivers/gpu/drm/bridge/chipone-icn6211.c   |2 +-
 drivers/gpu/drm/bridge/display-connector.c |1 -
 drivers/gpu/drm/bridge/fsl-ldb.c   |1 -
 drivers/gpu/drm/bridge/imx/imx8qm-ldb.c|2 +-
 drivers/gpu/drm/bridge/imx/imx8qxp-ldb.c   |1 +
 drivers/gpu/drm/bridge/lontium-lt9211.c|1 -
 drivers/gpu/drm/bridge/lvds-codec.c|1 -
 drivers/gpu/drm/bridge/nwl-dsi.c   |2 +-
 drivers/gpu/drm/bridge/parade-ps8622.c |1 -
 drivers/gpu/drm/bridge/samsung-dsim.c  |3 +-
 drivers/gpu/drm/bridge/simple-bridge.c |3 +-
 drivers/gpu/drm/bridge/synopsys/dw-hdmi.c  |2 +-
 drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c  |2 +-
 drivers/gpu/drm/bridge/ti-sn65dsi83.c  |2 +-
 drivers/gpu/drm/drm_debugfs.c  |   40 +
 drivers/gpu/drm/drm_drv.c  |8 +-
 drivers/gpu/drm/drm_gem.c  |3 +
 drivers/gpu/drm/drm_gpuva_mgr.c| 1725 
 drivers/gpu/drm/drm_internal.h |2 +
 drivers/gpu/drm/drm_ioctl.c|2 +
 drivers/gpu/drm/drm_mipi_dsi.c |1 +
 drivers/gpu/drm/drm_syncobj.c  |  148 +-
 drivers/gpu/drm/etnaviv/etnaviv_gpu.c  |2 +-
 drivers/gpu/drm/exynos/exynos5433_drm_decon.c  |2 +-
 drivers/gpu/drm/exynos/exynos7_drm_decon.c |1 -
 drivers/gpu/drm/exynos/exynos_drm_dsi.c|3 +-
 drivers/gpu/drm/exynos/exynos_drm_fimd.c   |1 -
 drivers/gpu/drm/exynos/exynos_drm_rotator.c|2 +-
 drivers/gpu/drm/exynos/exynos_drm_scaler.c |2 +-
 drivers/gpu/drm/exynos/exynos_hdmi.c   |2 +-
 drivers/gpu/drm/exynos/exynos_mixer.c  |1 -
 drivers/gpu/drm/hisilicon/kirin/kirin_drm_drv.c|2 +-
 drivers/gpu/drm/imx/dcss/dcss-dev.c|5 +-
 

[Intel-gfx] [PULL] drm-misc-fixes

2023-07-20 Thread Maxime Ripard
Hi,

Here's this week drm-misc-fixes PR

Maxime

drm-misc-fixes-2023-07-20:
Memory leak fixes in drm/client, memory access/leak fixes for
accel/qaic, another leak fix in dma-buf and three nouveau fixes around
hotplugging.
The following changes since commit 835a65f51790e1f72b1ab106ec89db9ac15b47d6:

  drm/nouveau: bring back blit subchannel for pre nv50 GPUs (2023-07-12 
22:38:41 +0200)

are available in the Git repository at:

  git://anongit.freedesktop.org/drm/drm-misc tags/drm-misc-fixes-2023-07-20

for you to fetch changes up to ea293f823a8805735d9e00124df81a8f448ed1ae:

  drm/nouveau/kms/nv50-: init hpd_irq_lock for PIOR DP (2023-07-19 11:08:47 
+0200)


Memory leak fixes in drm/client, memory access/leak fixes for
accel/qaic, another leak fix in dma-buf and three nouveau fixes around
hotplugging.


Ben Skeggs (3):
  drm/nouveau/i2c: fix number of aux event slots
  drm/nouveau/disp: PIOR DP uses GPIO for HPD, not PMGR AUX interrupts
  drm/nouveau/kms/nv50-: init hpd_irq_lock for PIOR DP

Dan Carpenter (4):
  accel/qaic: tighten bounds checking in encode_message()
  accel/qaic: tighten bounds checking in decode_message()
  accel/qaic: Add consistent integer overflow checks
  accel/qaic: Fix a leak in map_user_pages()

Jocelyn Falempe (2):
  drm/client: Fix memory leak in drm_client_target_cloned
  drm/client: Fix memory leak in drm_client_modeset_probe

Ville Syrjälä (1):
  dma-buf/dma-resv: Stop leaking on krealloc() failure

 drivers/accel/qaic/qaic_control.c | 39 +++
 drivers/dma-buf/dma-resv.c| 13 +---
 drivers/gpu/drm/drm_client_modeset.c  |  6 
 drivers/gpu/drm/nouveau/dispnv50/disp.c   |  4 +++
 drivers/gpu/drm/nouveau/include/nvkm/subdev/i2c.h |  4 +--
 drivers/gpu/drm/nouveau/nvkm/engine/disp/uconn.c  | 27 ++--
 drivers/gpu/drm/nouveau/nvkm/subdev/i2c/base.c| 11 +--
 7 files changed, 73 insertions(+), 31 deletions(-)


signature.asc
Description: PGP signature


Re: [Intel-gfx] [PATCH] drm: Replace drm_framebuffer plane size functions with its equivalents

2023-07-19 Thread Maxime Ripard
Hi,

On Mon, Jul 17, 2023 at 04:04:43PM -0300, Carlos wrote:
> On 7/12/23 20:30, André Almeida wrote:
> > Hi Carlos,
> > 
> > Em 27/06/2023 15:22, Carlos Eduardo Gallo Filho escreveu:
> > [...]
> > > 
> > > So, replace each drm_framebuffer_plane_{width,height} and
> > > fb_plane_{width,height} call to drm_format_info_plane_{width,height}
> > > and remove them.
> > > 
> > 
> > I see that with this replace, there's a small code change from
> > 
> > return DIV_ROUND_UP(width, format->hsub);
> > 
> > to
> > return width / info->hsub;
> > 
> > is there any case that the replaced function will give different results?
> 
> Well, short answer: Yes, and I'm already thinking on how do address it.
> 
> Taking a look at some drivers, I could notice that almost every driver do
> some similar calculating to obtain the size of a plane given the size of
> the first (I guess that they would be using these functions though). So, I
> stated that nearly all drivers implements this as a regular division, with
> exception of exynos, sun4i and i915 (counting with the replaced function),
> which all has at some point a DIV_ROUND_UP involving hsub or vsub.
> 
> Curiously, even the i915 having a DIV_ROUND_UP in some places, it also
> has regular division involving hsub/vsub in others, which leads me to
> guess if the chosen rounding method really matters. I also discovered
> the existence of the intel_plane_check_src_coordinates() function,
> that do some checks, which one of them consist of ensuring that for a
> plane, both source coordinates and sizes are multiples of the vsub and
> hsub, implying that no division rounding should occurs at all when it's
> used. However, I couldn't state if this function is always called for
> every source on every plane, so I can't assume anything from this.
> 
> Furthermore, I found the 33f673aa55e96 ("drm: Remove fb hsub/vsub
> alignment requirement") commit, that explains the motivation for having
> DIV_ROUND_UP on drm_framebuffer_plane_{width,height} functions. It says
> that the DIV_ROUND_UP is needed on places where the
> source isn't necessarily aligned with respect to the subsampling factors,
> that should be the sane default for a core function.

Honestly, I don't think there's a problem, but rather something that was
done in each and every driver differently and without a second thought.

I think we should indeed converge to a single helper, and if that helper
is broken fix it. It will be broken for everyone anyway.

So I can definitely see a patch that adds DIV_ROUND_UP() to
drm_plane_info_plane_width and height, and then the first patch of
yours.

> Saying that, I thought some ways to address this problem:
> 
> 1. Replace the regular division on drm_format_info_plane_{width,height}
>    functions to DIV_ROUND_UP so that we assert that this function is
>    always correct (as it seems that the places where regular division
>    is used assumes alignment, implying no division rounding at all).

+1

> 2. Create DIV_ROUND_UP variants of drm_format_info_plane_{width,height}
>    functions and use each of them in the right place. Maybe
>    let the default be the one with DIV_ROUND_UP and the
>    variant with regular division, naming it as something like
>    "drm_format_info_aligned_plane_{width,height}".

No, that won't work. Provided with a choice, a driver is most likely to
cargo-cult it anyway. And it's not like we know what we should do here.

Maxime


signature.asc
Description: PGP signature


Re: [Intel-gfx] [Freedreno] [PATCH RFC v1 00/52] drm/crtc: Rename struct drm_crtc::dev to drm_dev

2023-07-17 Thread Maxime Ripard
On Thu, Jul 13, 2023 at 04:14:55PM +0100, Tvrtko Ursulin wrote:
> 
> On 13/07/2023 16:09, Thomas Zimmermann wrote:
> > Hi
> > 
> > Am 13.07.23 um 16:41 schrieb Sean Paul:
> > > On Thu, Jul 13, 2023 at 9:04 AM Uwe Kleine-König
> > >  wrote:
> > > > 
> > > > hello Sean,
> > > > 
> > > > On Wed, Jul 12, 2023 at 02:31:02PM -0400, Sean Paul wrote:
> > > > > I'd really prefer this patch (series or single) is not accepted. This
> > > > > will cause problems for everyone cherry-picking patches to a
> > > > > downstream kernel (LTS or distro tree). I usually wouldn't expect
> > > > > sympathy here, but the questionable benefit does not outweigh the cost
> > > > > IM[biased]O.
> > > > 
> > > > I agree that for backports this isn't so nice. However with the split
> > > > approach (that was argumented against here) it's not soo bad. Patch #1
> > > > (and similar changes for the other affected structures) could be
> > > > trivially backported and with that it doesn't matter if you write dev or
> > > > drm (or whatever name is chosen in the end); both work in the same way.
> > > 
> > > Patch #1 avoids the need to backport the entire set, however every
> > > change occuring after the rename patches will cause conflicts on
> > > future cherry-picks. Downstream kernels will have to backport the
> > > whole set. Backporting the entire set will create an epoch in
> > > downstream kernels where cherry-picking patches preceding this set
> > > will need to undergo conflict resolution as well. As mentioned in my
> > > previous email, I don't expect sympathy here, it's part of maintaining
> > > a downstream kernel, but there is a real cost to kernel consumers.
> > > 
> > > > 
> > > > But even with the one-patch-per-rename approach I'd consider the
> > > > renaming a net win, because ease of understanding code has a big value.
> > > > It's value is not so easy measurable as "conflicts when backporting",
> > > > but it also matters in say two years from now, while backporting
> > > > shouldn't be an issue then any more.
> > > 
> > > You've rightly identified the conjecture in your statement. I've been
> > > on both sides of the argument, having written/maintained drm code
> > > upstream and cherry-picked changes to a downstream kernel. Perhaps
> > > it's because drm's definition of dev is ingrained in my muscle memory,
> > > or maybe it's because I don't do a lot of upstream development these
> > > days, but I just have a hard time seeing the benefit here.
> > 
> > I can only second what Sean writes. I've done quite a bit of backporting
> > of DRM code. It's hard already. And this kind of change is going to to
> > affect almost every backported DRM patch in the coming years. Not just
> > for distribution kernels, but also for upstream's stable series. It's
> > really only possible to do this change over many releases while keeping
> > compatible with the old name. So the more I think about it, the less I
> > like this change.
> 
> I've done my share of backporting, and still am doing it, so I can say I
> dislike it as much as anyone, however.. Is this an argument which the kernel
> as a wider entity typically accepts? If not could it be a slippery slope to
> start a precedent?
> 
> It is a honest question - I am not familiar if there were or were not any
> similar discussions in the past.

Eventually, it's a trade-off. There's always pros and cons to merging
every patch, and "backporting pains" is indeed not a very strong con.

But it's definitely the kind of patch where everyone and their mother
will have their opinion, without every reaching a clear consensus, and
there's no clear benefit either (but I might be biaised on that one).

So imo, while that downside is fairly weak, the pros are certainly
weaker.

> My gut feeling is that *if* there is a consensus that something _improves_
> the code base significantly, backporting pains should probably not be
> weighted very heavily as a contra argument.

100% agreed here, but I'm afraid we're far from that point.

Maxime


signature.asc
Description: PGP signature


Re: [Intel-gfx] [PATCH RFC v1 00/52] drm/crtc: Rename struct drm_crtc::dev to drm_dev

2023-07-13 Thread Maxime Ripard
On Wed, Jul 12, 2023 at 01:02:53PM +0200, Uwe Kleine-König wrote:
> > Background is that this makes merge conflicts easier to handle and detect.
> 
> Really?

FWIW, I agree with Christian here.

> Each file (apart from include/drm/drm_crtc.h) is only touched once. So
> unless I'm missing something you don't get less or easier conflicts by
> doing it all in a single patch. But you gain the freedom to drop a
> patch for one driver without having to drop the rest with it.

Not really, because the last patch removed the union anyway. So you have
to revert both the last patch, plus that driver one. And then you need
to add a TODO to remove that union eventually.

> So I still like the split version better, but I'm open to a more
> verbose reasoning from your side.

You're doing only one thing here, really: you change the name of a
structure field. If it was shared between multiple maintainers, then
sure, splitting that up is easier for everyone, but this will go through
drm-misc, so I can't see the benefit it brings.

Maxime


signature.asc
Description: PGP signature


Re: [Intel-gfx] [PATCH RFC v1 00/52] drm/crtc: Rename struct drm_crtc::dev to drm_dev

2023-07-13 Thread Maxime Ripard
On Wed, Jul 12, 2023 at 03:38:03PM +0200, Uwe Kleine-König wrote:
> Hello Maxime,
> 
> On Wed, Jul 12, 2023 at 02:52:38PM +0200, Maxime Ripard wrote:
> > On Wed, Jul 12, 2023 at 01:02:53PM +0200, Uwe Kleine-König wrote:
> > > > Background is that this makes merge conflicts easier to handle and 
> > > > detect.
> > > 
> > > Really?
> > 
> > FWIW, I agree with Christian here.
> > 
> > > Each file (apart from include/drm/drm_crtc.h) is only touched once. So
> > > unless I'm missing something you don't get less or easier conflicts by
> > > doing it all in a single patch. But you gain the freedom to drop a
> > > patch for one driver without having to drop the rest with it.
> > 
> > Not really, because the last patch removed the union anyway. So you have
> > to revert both the last patch, plus that driver one. And then you need
> > to add a TODO to remove that union eventually.
> 
> Yes, with a single patch you have only one revert (but 194 files changed,
> 1264 insertions(+), 1296 deletions(-)) instead of two (one of them: 1
> file changed, 9 insertions(+), 1 deletion(-); the other maybe a bit
> bigger). (And maybe you get away with just reverting the last patch.)
> 
> With a single patch the TODO after a revert is "redo it all again (and
> prepare for a different set of conflicts)" while with the split series
> it's only "fix that one driver that was forgotten/borked" + reapply that
> 10 line patch. As the one who gets that TODO, I prefer the latter.
> 
> So in sum: If your metric is "small count of reverted commits", you're
> right. If however your metric is: Better get 95% of this series' change
> in than maybe 0%, the split series is the way to do it.

I guess that's where we disagree: I don't see the point of having 95% of
it, either 0 or 100.

> With me having spend ~3h on this series' changes, it's maybe
> understandable that I did it the way I did.

I'm sorry, but that's never been an argument? I'm sure you and I both
have had series that took much longer dropped because it wasn't the
right approach.

> FTR: This series was created on top of v6.5-rc1. If you apply it to
> drm-misc-next you get a (trivial) conflict in patch #2. If I consider to
> be the responsible maintainer who applies this series, I like being able
> to just do git am --skip then. 

Or we can ask that the driver is based on drm-misc-next ...

> FTR#2: In drm-misc-next is a new driver
> (drivers/gpu/drm/loongson/lsdc_crtc.c) so skipping the last patch for
> now might indeed be a good idea.

... which is going to fix that one too.

Maxime


signature.asc
Description: PGP signature


[Intel-gfx] [PULL] drm-misc-fixes

2023-07-13 Thread Maxime Ripard
Hi,

Sending again because I had to send it by hand and forgot to add all the
recipients in Cc.

Here's this week drm-misc-fixes PR, plus last week as well that got
dropped for some reason.

Thanks!
Maxime

The following changes since commit 06c2afb862f9da8dc5efa4b6076a0e48c3fbaaa5:

  Linux 6.5-rc1 (2023-07-09 13:53:13 -0700)

are available in the Git repository at:

  ssh://git.freedesktop.org/git/drm/drm-misc tags/drm-misc-fixes-2023-07-13

for you to fetch changes up to 835a65f51790e1f72b1ab106ec89db9ac15b47d6:

  drm/nouveau: bring back blit subchannel for pre nv50 GPUs (2023-07-12 
22:38:41 +0200)


A couple of nouveau patches addressing improving HDMI support and
firmware handling, a fix for TTM to skip pinned BO when evicting, and a
fix for the fbdev documentation.


Adrián Larumbe (1):
  drm: bridge: dw_hdmi: fix connector access for scdc

Boris Brezillon (2):
  drm/sched: Make sure we wait for all dependencies in kill_jobs_cb()
  drm/sched: Call drm_sched_fence_set_parent() from 
drm_sched_fence_scheduled()

Christian König (3):
  drm/ttm: fix warning that we shouldn't mix && and ||
  dma-buf: keep the signaling time of merged fences v3
  drm/ttm: never consider pinned BOs for eviction

Dan Carpenter (1):
  dma-buf: fix an error pointer vs NULL bug

Douglas Anderson (1):
  drm/bridge: ti-sn65dsi86: Fix auxiliary bus lifetime

Fabio Estevam (1):
  drm/panel: simple: Add connector_type for innolux_at043tn24

Geert Uytterhoeven (1):
  drm/fbdev-dma: Fix documented default preferred_bpp value

Karol Herbst (4):
  drm/nouveau/disp: fix HDMI on gt215+
  drm/nouveau/disp/g94: enable HDMI
  drm/nouveau/acr: Abort loading ACR if no firmware was found
  drm/nouveau: bring back blit subchannel for pre nv50 GPUs

Karol Wachowski (2):
  accel/ivpu: Fix VPU register access in irq disable
  accel/ivpu: Clear specific interrupt status bits on C0

Lyude Paul (1):
  drm/nouveau/kms/nv50-: Fix drm_dp_remove_payload() invocation

Marek Vasut (1):
  drm/panel: simple: Add Powertip PH800480T013 drm_display_mode flags

Maxime Ripard (1):
  Merge v6.5-rc1 into drm-misc-fixes

Thomas Hellström (2):
  drm/ttm: Don't leak a resource on eviction error
  drm/ttm: Don't leak a resource on swapout move error

Thomas Zimmermann (1):
  drm/client: Send hotplug event after registering a client

Yunxiang Li (1):
  drm/ttm: fix bulk_move corruption when adding a entry

 drivers/accel/ivpu/ivpu_drv.h|  1 +
 drivers/accel/ivpu/ivpu_hw_mtl.c | 20 
 drivers/dma-buf/dma-fence-unwrap.c   | 26 ---
 drivers/dma-buf/dma-fence.c  |  7 ++--
 drivers/gpu/drm/armada/armada_fbdev.c|  4 ---
 drivers/gpu/drm/bridge/synopsys/dw-hdmi.c|  9 +++---
 drivers/gpu/drm/bridge/ti-sn65dsi86.c| 35 
 drivers/gpu/drm/drm_client.c | 21 
 drivers/gpu/drm/drm_fbdev_dma.c  |  6 +---
 drivers/gpu/drm/drm_fbdev_generic.c  |  4 ---
 drivers/gpu/drm/drm_syncobj.c|  6 ++--
 drivers/gpu/drm/exynos/exynos_drm_fbdev.c|  4 ---
 drivers/gpu/drm/gma500/fbdev.c   |  4 ---
 drivers/gpu/drm/msm/msm_fbdev.c  |  4 ---
 drivers/gpu/drm/nouveau/dispnv50/disp.c  |  8 +++--
 drivers/gpu/drm/nouveau/nouveau_chan.c   |  1 +
 drivers/gpu/drm/nouveau/nouveau_chan.h   |  1 +
 drivers/gpu/drm/nouveau/nouveau_drm.c| 20 ++--
 drivers/gpu/drm/nouveau/nvkm/engine/disp/g94.c   |  1 +
 drivers/gpu/drm/nouveau/nvkm/engine/disp/gt215.c |  2 +-
 drivers/gpu/drm/nouveau/nvkm/subdev/acr/base.c   |  2 +-
 drivers/gpu/drm/omapdrm/omap_fbdev.c |  4 ---
 drivers/gpu/drm/panel/panel-simple.c |  2 ++
 drivers/gpu/drm/radeon/radeon_fbdev.c|  4 ---
 drivers/gpu/drm/scheduler/sched_entity.c | 41 +++-
 drivers/gpu/drm/scheduler/sched_fence.c  | 40 ++-
 drivers/gpu/drm/scheduler/sched_main.c   |  3 +-
 drivers/gpu/drm/tegra/fbdev.c|  4 ---
 drivers/gpu/drm/ttm/ttm_bo.c | 29 ++---
 drivers/gpu/drm/ttm/ttm_resource.c   |  5 ++-
 include/drm/gpu_scheduler.h  |  5 ++-
 include/linux/dma-fence.h|  2 +-
 32 files changed, 206 insertions(+), 119 deletions(-)


signature.asc
Description: PGP signature


[Intel-gfx] [PULL] drm-misc-next

2023-05-11 Thread Maxime Ripard
drm/bridge: tc358768: Add atomic_get_input_bus_fmts() implementation
  drm/bridge: tc358768: always enable HS video mode
  drm/bridge: tc358768: fix PLL parameters computation
  drm/bridge: tc358768: fix PLL target frequency
  drm/bridge: tc358768: fix TCLK_ZEROCNT computation
  drm/bridge: tc358768: fix TCLK_TRAILCNT computation
  drm/bridge: tc358768: fix THS_ZEROCNT computation
  drm/bridge: tc358768: fix TXTAGOCNT computation
  drm/bridge: tc358768: fix THS_TRAILCNT computation
  drm/bridge: tc358768: remove unused variable

Jani Nikula (3):
  drm/sti/sti_hdmi: convert to using is_hdmi from display info
  drm/rockchip: cdn-dp: call drm_connector_update_edid_property() 
unconditionally
  drm/connector: document enum drm_connector_tv_mode DRM_MODE_TV_MODE_MAX

Konrad Dybcio (4):
  dt-bindings: display: panel: nt36523: Add Lenovo J606F panel
  drm/panel: nt36523: Add DCS backlight support
  drm/panel: nt36523: Get orientation from OF
  drm/panel: nt36523: Add Lenovo J606F panel

Luc Ma (1):
  drm/vram-helper: fix function names in vram helper doc

Marek Vasut (2):
  drm/bridge: lt9211: Do not generate HFP/HBP/HSA and EOT packet
  drm/bridge: lt9611: Do not generate HFP/HBP/HSA and EOT packet

Markus Elfring (10):
  drm/nouveau/debugfs: Move an expression into a function call parameter in 
nouveau_debugfs_pstate_set()
  drm/nouveau/debugfs: Move a variable assignment behind a null pointer 
check in nouveau_debugfs_pstate_get()
  drm/nouveau/debugfs: Use seq_putc() in nouveau_debugfs_pstate_get()
  drm/nouveau/debugfs: Replace five seq_printf() calls by seq_puts() in 
nouveau_debugfs_pstate_get()
  drm/nouveau/bios/power_budget: Move an expression into a macro call 
parameter in nvbios_power_budget_header()
  drm/nouveau/clk: Move a variable assignment behind a null pointer check 
in nvkm_pstate_new()
  drm/nouveau/pci: Move a variable assignment behind condition checks in 
nvkm_pcie_set_link()
  drm/nouveau/pci: Move an expression into a function call parameter in 
nvkm_pcie_set_link()
  drm/nouveau/therm: Move an assignment statement behind a null pointer 
check in two functions
  drm/bridge: it6505: Move a variable assignment behind a null pointer 
check in receive_timing_debugfs_show()

Maxime Ripard (3):
  drm/vc4: Switch to container_of_const
  drm/vc4: hdmi: Update all the planes if the TV margins are changed
  Merge drm/drm-next into drm-misc-next

Maíra Canal (14):
  drm/vkms: Use drmm_crtc_init_with_planes()
  drm/vkms: Use drmm_mode_config_init()
  drm/gem: Check for valid formats
  drm/bridge: anx7625: Drop of_gpio header
  drm/sti: Drop of_gpio header
  drm/vkms: isolate pixel conversion functionality
  drm/vkms: allow full alpha blending on all planes
  drm/vkms: drop full alpha blending TODO
  drm/vkms: add rotate-0 and reflect-x property
  drm/vkms: add reflect-y and rotate-180 property
  drm/vkms: add rotate-90 property
  drm/vkms: add rotate-270 property
  drm/vkms: drop "Rotation" TODO
  MAINTAINERS: Add Maira to VKMS maintainers

Nikita Travkin (1):
  drm/bridge: ti-sn65dsi86: Implement wait_hpd_asserted

Richard Leitner (2):
  dt-bindings: display: simple: add support for InnoLux G070ACE-L01
  drm/panel: simple: Add InnoLux G070ACE-L01

Rodrigo Siqueira (1):
  drm/display: Add missing OLED Vesa brightnesses definitions

Rodrigo Vivi (1):
  drm/doc/rfc: Introduce the merge plan for the Xe driver.

Roman Beranek (2):
  drm: sun4i: rename sun4i_dotclock to sun4i_tcon_dclk
  drm: sun4i: calculate proper DCLK rate for DSI

Sui Jingfeng (1):
  dma-buf/dma-resv.c: fix a typo

Thomas Zimmermann (46):
  video/aperture: Provide a VGA helper for gma500 and internal use
  Merge drm/drm-next into drm-misc-next
  fbdev: Prepare generic architecture helpers
  arch/arc: Implement  with generic helpers
  arch/arm: Implement  with generic helpers
  arch/arm64: Implement  with generic helpers
  arch/ia64: Implement  with generic helpers
  arch/loongarch: Implement  with generic helpers
  arch/m68k: Merge variants of fb_pgprotect() into single function
  arch/m68k: Implement  with generic helpers
  arch/mips: Implement  with generic helpers
  video: Remove trailing whitespaces
  video: Move HP PARISC STI core code to shared location
  arch/parisc: Remove trailing whitespaces
  arch/parisc: Implement fb_is_primary_device() under arch/parisc
  arch/parisc: Implement  with generic helpers
  arch/powerpc: Implement  with generic helpers
  arch/sh: Implement  with generic helpers
  arch/sparc: Implement fb_is_primary_device() in source file
  arch/sparc: Implement  with generic helpers
  arch/x86: Implement  with generic helpers
  drm/armada: Include 
  drm/armada: Hide fbdev support behind config opt

Re: [Intel-gfx] [PATCH v2] drm/scdc-helper: Pimp SCDC debugs

2023-04-04 Thread Maxime Ripard
On Tue, Apr 04, 2023 at 01:36:52AM +0300, Ville Syrjala wrote:
> From: Ville Syrjälä 
> 
> Include the device and connector information in the SCDC
> debugs. Makes it easier to figure out who did what.
> 
> v2: Rely on connector->ddc (Maxime)
> 
> Cc: Andrzej Hajda 
> Cc: Neil Armstrong 
> Cc: Robert Foss 
> Cc: Laurent Pinchart 
> Cc: Jonas Karlman 
> Cc: Jernej Skrabec 
> Cc: Thierry Reding 
> Cc: Emma Anholt 
> Cc: Maxime Ripard 
> Cc: intel-gfx@lists.freedesktop.org
> Cc: linux-te...@vger.kernel.org
> Signed-off-by: Ville Syrjälä 

Acked-by: Maxime Ripard 

Thanks!
Maxime


Re: [Intel-gfx] [PATCH] drm/scdc-helper: Pimp SCDC debugs

2023-03-30 Thread Maxime Ripard
Hi,

On Wed, Mar 29, 2023 at 08:14:02PM +0300, Ville Syrjala wrote:
> diff --git a/drivers/gpu/drm/display/drm_scdc_helper.c 
> b/drivers/gpu/drm/display/drm_scdc_helper.c
> index c3ad4ab2b456..2b124152384c 100644
> --- a/drivers/gpu/drm/display/drm_scdc_helper.c
> +++ b/drivers/gpu/drm/display/drm_scdc_helper.c
> @@ -26,6 +26,8 @@
>  #include 
>  
>  #include 
> +#include 
> +#include 
>  #include 
>  
>  /**
> @@ -140,6 +142,7 @@ EXPORT_SYMBOL(drm_scdc_write);
>  
>  /**
>   * drm_scdc_get_scrambling_status - what is status of scrambling?
> + * @connector: connector
>   * @adapter: I2C adapter for DDC channel
>   *
>   * Reads the scrambler status over SCDC, and checks the
> @@ -148,14 +151,17 @@ EXPORT_SYMBOL(drm_scdc_write);
>   * Returns:
>   * True if the scrambling is enabled, false otherwise.
>   */
> -bool drm_scdc_get_scrambling_status(struct i2c_adapter *adapter)
> +bool drm_scdc_get_scrambling_status(struct drm_connector *connector,
> + struct i2c_adapter *adapter)

Is there any driver where adapter isn't equal to connector->ddc?

If not, there's no reason to pass both

Maxime


Re: [Intel-gfx] [PATCH] drm/atomic-helpers: remove legacy_cursor_update hacks

2023-03-07 Thread Maxime Ripard
Hi,

On Thu, Feb 16, 2023 at 12:12:13PM +0100, Daniel Vetter wrote:
> The stuff never really worked, and leads to lots of fun because it
> out-of-order frees atomic states. Which upsets KASAN, among other
> things.
> 
> For async updates we now have a more solid solution with the
> ->atomic_async_check and ->atomic_async_commit hooks. Support for that
> for msm and vc4 landed. nouveau and i915 have their own commit
> routines, doing something similar.
> 
> For everyone else it's probably better to remove the use-after-free
> bug, and encourage folks to use the async support instead. The
> affected drivers which register a legacy cursor plane and don't either
> use the new async stuff or their own commit routine are: amdgpu,
> atmel, mediatek, qxl, rockchip, sti, sun4i, tegra, virtio, and vmwgfx.
> 
> Inspired by an amdgpu bug report.

Thanks for submitting that patch. It's been in the downstream RPi tree
for a while, so I'd really like it to be merged eventually :)

Acked-by: Maxime Ripard 

Maxime


signature.asc
Description: PGP signature


Re: [Intel-gfx] [PULL] drm-misc-next-fixes

2023-02-23 Thread Maxime Ripard
Hi Maarten,

On Thu, Feb 23, 2023 at 07:25:23PM +0100, Maarten Lankhorst wrote:
> Hi Dave and Daniel,
> 
> Here's the first pull request for v6.4-rc1.
> 
> Enjoy!
> 
> ~Maarten
> 
> drm-misc-next-2023-02-23:
> drm-misc-next for v6.4-rc1:
> 
> First pull request to keep the delta from growing too big.

This isn't drm-misc-next-fixes but drm-misc-next?

Maxime


signature.asc
Description: PGP signature


[Intel-gfx] [PULL] drm-misc-fixes

2023-02-23 Thread Maxime Ripard
Hi Dave, Daniel,

Here's this week drm-misc-fixes PR

Maxime

drm-misc-fixes-2023-02-23:
A fix for nouveau preventing the system shutdown and one for a build
warning, and NULL pointer dereference fix for cirrus.
The following changes since commit a950b989ea29ab3b38ea7f6e3d2540700a3c54e8:

  drm/vmwgfx: Do not drop the reference to the handle too soon (2023-02-14 
23:00:09 -0500)

are available in the Git repository at:

  git://anongit.freedesktop.org/drm/drm-misc tags/drm-misc-fixes-2023-02-23

for you to fetch changes up to 1b9b4f922f96108da3bb5d87b2d603f5dfbc5650:

  drm/nouveau/fb/gp102-: cache scrubber binary on first load (2023-02-21 
02:07:24 +0100)


A fix for nouveau preventing the system shutdown and one for a build
warning, and NULL pointer dereference fix for cirrus.


Alexandr Sapozhnikov (1):
  drm/cirrus: NULL-check pipe->plane.state->fb in cirrus_pipe_update()

Ben Skeggs (1):
  drm/nouveau/fb/gp102-: cache scrubber binary on first load

Jiri Slaby (SUSE) (1):
  drm/nouveau/kms/nv50: fix nv50_wndw_new_ prototype

 drivers/gpu/drm/nouveau/dispnv50/wndw.h  |  5 +--
 drivers/gpu/drm/nouveau/include/nvkm/subdev/fb.h |  3 +-
 drivers/gpu/drm/nouveau/nvkm/subdev/fb/base.c|  8 +++--
 drivers/gpu/drm/nouveau/nvkm/subdev/fb/ga100.c   |  2 +-
 drivers/gpu/drm/nouveau/nvkm/subdev/fb/ga102.c   | 21 +---
 drivers/gpu/drm/nouveau/nvkm/subdev/fb/gp102.c   | 41 
 drivers/gpu/drm/nouveau/nvkm/subdev/fb/gv100.c   |  4 +--
 drivers/gpu/drm/nouveau/nvkm/subdev/fb/priv.h|  3 +-
 drivers/gpu/drm/nouveau/nvkm/subdev/fb/tu102.c   |  4 +--
 drivers/gpu/drm/tiny/cirrus.c|  2 +-
 10 files changed, 40 insertions(+), 53 deletions(-)


signature.asc
Description: PGP signature


[Intel-gfx] [PULL] drm-misc-fixes

2023-02-16 Thread Maxime Ripard
Hi Dave, Daniel,

Here's this week drm-misc-fixes PR.

Maxime

drm-misc-fixes-2023-02-16:
Multiple fixes in vc4 to address issues with YUV planes, HDMI and CRTC;
an invalid page access fix for fbdev, mark dynamic debug as broken, a
double free and refcounting fix for vmwgfx.
The following changes since commit 85e26dd5100a182bf8448050427539c0a66ab793:

  drm/client: fix circular reference counting issue (2023-02-07 09:42:56 +0100)

are available in the Git repository at:

  git://anongit.freedesktop.org/drm/drm-misc tags/drm-misc-fixes-2023-02-16

for you to fetch changes up to a950b989ea29ab3b38ea7f6e3d2540700a3c54e8:

  drm/vmwgfx: Do not drop the reference to the handle too soon (2023-02-14 
23:00:09 -0500)


Multiple fixes in vc4 to address issues with YUV planes, HDMI and CRTC;
an invalid page access fix for fbdev, mark dynamic debug as broken, a
double free and refcounting fix for vmwgfx.


Dave Stevenson (1):
  drm/vc4: Fix YUV plane handling when planes are in different buffers

Dom Cobley (2):
  drm/vc4: hdmi: Always enable GCP with AVMUTE cleared
  drm/vc4: crtc: Increase setup cost in core clock calculation to handle 
extreme reduced blanking

Jocelyn Falempe (1):
  drm/ast: Fix start address computation

Takashi Iwai (1):
  fbdev: Fix invalid page access after closing deferred I/O devices

Ville Syrjälä (1):
  drm: Disable dynamic debug as broken

Zack Rusin (2):
  drm/vmwgfx: Stop accessing buffer objects which failed init
  drm/vmwgfx: Do not drop the reference to the handle too soon

 drivers/gpu/drm/Kconfig |  3 ++-
 drivers/gpu/drm/ast/ast_mode.c  |  4 ++--
 drivers/gpu/drm/vc4/vc4_crtc.c  |  2 +-
 drivers/gpu/drm/vc4/vc4_hdmi.c  | 18 +-
 drivers/gpu/drm/vc4/vc4_plane.c |  6 --
 drivers/gpu/drm/vmwgfx/vmwgfx_bo.c  | 12 
 drivers/gpu/drm/vmwgfx/vmwgfx_execbuf.c |  2 ++
 drivers/gpu/drm/vmwgfx/vmwgfx_gem.c |  8 
 drivers/gpu/drm/vmwgfx/vmwgfx_kms.c |  4 +++-
 drivers/gpu/drm/vmwgfx/vmwgfx_overlay.c |  1 +
 drivers/gpu/drm/vmwgfx/vmwgfx_shader.c  |  1 +
 drivers/gpu/drm/vmwgfx/vmwgfx_surface.c | 10 ++
 drivers/video/fbdev/core/fb_defio.c | 10 +-
 drivers/video/fbdev/core/fbmem.c|  4 
 include/linux/fb.h  |  1 +
 15 files changed, 57 insertions(+), 29 deletions(-)


signature.asc
Description: PGP signature


[Intel-gfx] [PULL] drm-misc-fixes

2023-02-09 Thread Maxime Ripard
Hi Dave, Daniel,

Here's this week drm-misc-fixes PR

Maxime

drm-misc-fixes-2023-02-09:
A fix for a circular refcounting in drm/client, one for a memory leak in
amdgpu and a virtio fence fix when interrupted
The following changes since commit a3ee9e0b57f8ecca02d1c16fad4941e09bfe2941:

  drm/panel: boe-tv101wum-nl6: Ensure DSI writes succeed during disable 
(2023-02-01 11:41:15 +0100)

are available in the Git repository at:

  git://anongit.freedesktop.org/drm/drm-misc tags/drm-misc-fixes-2023-02-09

for you to fetch changes up to 85e26dd5100a182bf8448050427539c0a66ab793:

  drm/client: fix circular reference counting issue (2023-02-07 09:42:56 +0100)


A fix for a circular refcounting in drm/client, one for a memory leak in
amdgpu and a virtio fence fix when interrupted


Bert Karwatzki (1):
  drm/amdgpu: fix memory leak in amdgpu_cs_sync_rings

Christian König (1):
  drm/client: fix circular reference counting issue

Ryan Neph (1):
  drm/virtio: exbuf->fence_fd unmodified on interrupted wait

 drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c |  5 -
 drivers/gpu/drm/drm_client.c   | 33 -
 drivers/gpu/drm/virtio/virtgpu_ioctl.c |  5 +
 include/drm/drm_client.h   |  5 -
 include/uapi/drm/virtgpu_drm.h |  1 +
 5 files changed, 26 insertions(+), 23 deletions(-)


signature.asc
Description: PGP signature


[Intel-gfx] [PULL] drm-misc-fixes

2023-02-02 Thread Maxime Ripard
Hi,

Here's this week drm-misc-fixes PR

Maxime

drm-misc-fixes-2023-02-02:
A fix for a non-unique CEC adapter name registration in vc4, a
regression breaking the display in ssd130x, a signaling bit issue in
dma-fence, a couple of fixes in nouveau for Turing and Ampere, and a
disable fix for the boe-tv101wum-nl6 panel.
The following changes since commit d6591da5f3ff284a376d56b5f7a48a34e9cb159d:

  drm/fb-helper: Use a per-driver FB deferred I/O handler (2023-01-24 11:13:08 
+0100)

are available in the Git repository at:

  git://anongit.freedesktop.org/drm/drm-misc tags/drm-misc-fixes-2023-02-02

for you to fetch changes up to a3ee9e0b57f8ecca02d1c16fad4941e09bfe2941:

  drm/panel: boe-tv101wum-nl6: Ensure DSI writes succeed during disable 
(2023-02-01 11:41:15 +0100)


A fix for a non-unique CEC adapter name registration in vc4, a
regression breaking the display in ssd130x, a signaling bit issue in
dma-fence, a couple of fixes in nouveau for Turing and Ampere, and a
disable fix for the boe-tv101wum-nl6 panel.


Ben Skeggs (3):
  drm/nouveau/devinit/tu102-: wait for GFW_BOOT_PROGRESS == COMPLETED
  drm/nouveau/fb/tu102-: fix register used to determine scrub status
  drm/nouveau/acr/gm20b: regression fixes

Danilo Krummrich (1):
  dma-buf: actually set signaling bit for private stub fences

Hans Verkuil (1):
  drm/vc4: hdmi: make CEC adapter name unique

Javier Martinez Canillas (1):
  drm/ssd130x: Init display before the SSD130X_DISPLAY_ON command

Stephen Boyd (1):
  drm/panel: boe-tv101wum-nl6: Ensure DSI writes succeed during disable

 drivers/dma-buf/dma-fence.c|  2 +-
 drivers/gpu/drm/nouveau/include/nvkm/subdev/fb.h   |  1 +
 drivers/gpu/drm/nouveau/nvkm/core/firmware.c   |  3 ++
 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c  | 10 ++--
 drivers/gpu/drm/nouveau/nvkm/falcon/gm200.c| 14 +-
 .../gpu/drm/nouveau/nvkm/subdev/devinit/tu102.c| 23 +
 drivers/gpu/drm/nouveau/nvkm/subdev/fb/Kbuild  |  1 +
 drivers/gpu/drm/nouveau/nvkm/subdev/fb/ga102.c |  8 +---
 drivers/gpu/drm/nouveau/nvkm/subdev/fb/gv100.c |  5 --
 drivers/gpu/drm/nouveau/nvkm/subdev/fb/priv.h  |  2 +
 drivers/gpu/drm/nouveau/nvkm/subdev/fb/tu102.c | 55 ++
 drivers/gpu/drm/nouveau/nvkm/subdev/pmu/gm20b.c|  2 +-
 drivers/gpu/drm/panel/panel-boe-tv101wum-nl6.c | 16 +--
 drivers/gpu/drm/solomon/ssd130x.c  | 18 +++
 drivers/gpu/drm/vc4/vc4_hdmi.c |  3 +-
 15 files changed, 127 insertions(+), 36 deletions(-)
 create mode 100644 drivers/gpu/drm/nouveau/nvkm/subdev/fb/tu102.c


signature.asc
Description: PGP signature


[Intel-gfx] [PULL] drm-misc-fixes

2023-01-26 Thread Maxime Ripard
Hi Dave, Daniel,

Here's this week drm-misc-fixes PR

Maxime

drm-misc-fixes-2023-01-26:
A fix and a preliminary patch to fix a memory leak in i915, and a use
after free fix for fbdev deferred io
The following changes since commit 2293a73ad4f3b6c37c06713ff1b67659d92ef43d:

  drm/i915: Remove unused variable (2023-01-18 13:33:15 -0500)

are available in the Git repository at:

  git://anongit.freedesktop.org/drm/drm-misc tags/drm-misc-fixes-2023-01-26

for you to fetch changes up to d6591da5f3ff284a376d56b5f7a48a34e9cb159d:

  drm/fb-helper: Use a per-driver FB deferred I/O handler (2023-01-24 11:13:08 
+0100)


A fix and a preliminary patch to fix a memory leak in i915, and a use
after free fix for fbdev deferred io


Javier Martinez Canillas (2):
  drm/fb-helper: Check fb_deferred_io_init() return value
  drm/fb-helper: Use a per-driver FB deferred I/O handler

Nirmoy Das (2):
  drm/drm_vma_manager: Add drm_vma_node_allow_once()
  drm/i915: Fix a memory leak with reused mmap_offset

 drivers/gpu/drm/drm_fbdev_generic.c  | 15 ---
 drivers/gpu/drm/drm_vma_manager.c| 76 +++-
 drivers/gpu/drm/i915/gem/i915_gem_mman.c |  2 +-
 include/drm/drm_fb_helper.h  | 12 +
 include/drm/drm_vma_manager.h|  1 +
 5 files changed, 76 insertions(+), 30 deletions(-)


signature.asc
Description: PGP signature


Re: [Intel-gfx] [PATCH 1/2] drm/drm_vma_manager: Add drm_vma_node_allow_once()

2023-01-19 Thread Maxime Ripard
On Tue, 17 Jan 2023 18:52:35 +0100, Nirmoy Das wrote:
> Currently there is no easy way for a drm driver to safely check and allow
> drm_vma_offset_node for a drm file just once. Allow drm drivers to call
> non-refcounted version of drm_vma_node_allow() so that a driver doesn't
> need to keep track of each drm_vma_node_allow() to call subsequent
> drm_vma_node_revoke() to prevent memory leak.
> 
> Cc: Maarten Lankhorst 
> Cc: Maxime Ripard 
> Cc: Thomas Zimmermann 
> Cc: David Airlie 
> Cc: Daniel Vetter 
> Cc: Tvrtko Ursulin 
> Cc: Andi Shyti 
> 
> [...]

Applied to drm/drm-misc (drm-misc-fixes).

Thanks!
Maxime


[Intel-gfx] [PULL] drm-misc-fixes

2023-01-19 Thread Maxime Ripard
Hi Dave, Daniel,

Here's this week drm-misc-fixes PR

Thanks!
Maxime

drm-misc-fixes-2023-01-19:
A fix for vc4 to address a memory leak when allocating a buffer, a
Kconfig fix for panfrost and two fixes for i915 and fb-helper to
address some bugs with vga-switcheroo.
The following changes since commit 5640e81607152d7f2d2558227c0f6cb78b8f39cf:

  drm: Optimize drm buddy top-down allocation method (2023-01-12 13:50:28 +0100)

are available in the Git repository at:

  git://anongit.freedesktop.org/drm/drm-misc tags/drm-misc-fixes-2023-01-19

for you to fetch changes up to 2293a73ad4f3b6c37c06713ff1b67659d92ef43d:

  drm/i915: Remove unused variable (2023-01-18 13:33:15 -0500)


A fix for vc4 to address a memory leak when allocating a buffer, a
Kconfig fix for panfrost and two fixes for i915 and fb-helper to
address some bugs with vga-switcheroo.


Arnd Bergmann (1):
  drm/panfrost: fix GENERIC_ATOMIC64 dependency

Maxime Ripard (2):
  drm/vc4: bo: Fix drmm_mutex_init memory hog
  drm/vc4: bo: Fix unused variable warning

Nirmoy Das (1):
  drm/i915: Remove unused variable

Thomas Zimmermann (2):
  drm/i915: Allow switching away via vga-switcheroo if uninitialized
  drm/fb-helper: Set framebuffer for vga-switcheroo clients

 drivers/gpu/drm/drm_fb_helper.c| 7 +++
 drivers/gpu/drm/i915/i915_driver.c | 5 +
 drivers/gpu/drm/i915/i915_switcheroo.c | 6 +-
 drivers/gpu/drm/panfrost/Kconfig   | 3 ++-
 drivers/gpu/drm/vc4/vc4_bo.c   | 6 ++
 5 files changed, 17 insertions(+), 10 deletions(-)


signature.asc
Description: PGP signature


[Intel-gfx] [PULL] drm-misc-fixes

2023-01-12 Thread Maxime Ripard
Hi Dave, Daniel,

Here's this week drm-misc-fixes PR

Maxime

drm-misc-fixes-2023-01-12:
Several fixes for amdgpu (all addressing issues with fences), yet
another orientation quirk for a Lenovo device, a use-after-free fix for
virtio, a regression fix in TTM and a performance regression in drm
buddy.
The following changes since commit 83e79ae3216c70f2b63c935a4e089d1620e8ef01:

  Merge tag 'drm-misc-fixes-2023-01-05' of 
git://anongit.freedesktop.org/drm/drm-misc into drm-fixes (2023-01-05 09:43:37 
+0100)

are available in the Git repository at:

  git://anongit.freedesktop.org/drm/drm-misc tags/drm-misc-fixes-2023-01-12

for you to fetch changes up to 5640e81607152d7f2d2558227c0f6cb78b8f39cf:

  drm: Optimize drm buddy top-down allocation method (2023-01-12 13:50:28 +0100)


Several fixes for amdgpu (all addressing issues with fences), yet
another orientation quirk for a Lenovo device, a use-after-free fix for
virtio, a regression fix in TTM and a performance regression in drm
buddy.


Arunpravin Paneer Selvam (1):
  drm: Optimize drm buddy top-down allocation method

Christian König (3):
  drm/amdgpu: fix another missing fence reference in the CS code
  drm/amdgpu: fix missing dma_fence_put in error path
  drm/amdgpu: fix pipeline sync v2

Patrick Thompson (1):
  drm: Add orientation quirk for Lenovo ideapad D330-10IGL

Rob Clark (1):
  drm/virtio: Fix GEM handle creation UAF

Thomas Zimmermann (1):
  drm/nouveau: Remove file nouveau_fbcon.c

Zack Rusin (2):
  drm/vmwgfx: Remove rcu locks from user resources
  drm/ttm: Fix a regression causing kernel oops'es

 drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c |  51 +-
 drivers/gpu/drm/amd/amdgpu/amdgpu_sync.c   |   4 +-
 drivers/gpu/drm/drm_buddy.c|  81 ++--
 drivers/gpu/drm/drm_panel_orientation_quirks.c |   6 +
 drivers/gpu/drm/nouveau/nouveau_fbcon.c| 613 -
 drivers/gpu/drm/ttm/ttm_bo_util.c  |   2 +-
 drivers/gpu/drm/virtio/virtgpu_ioctl.c |  19 +-
 drivers/gpu/drm/vmwgfx/ttm_object.c|  41 +-
 drivers/gpu/drm/vmwgfx/ttm_object.h|  14 -
 drivers/gpu/drm/vmwgfx/vmwgfx_bo.c |  38 --
 drivers/gpu/drm/vmwgfx/vmwgfx_drv.h|  18 +-
 drivers/gpu/drm/vmwgfx/vmwgfx_execbuf.c| 176 ---
 drivers/gpu/drm/vmwgfx/vmwgfx_resource.c   |  33 --
 13 files changed, 202 insertions(+), 894 deletions(-)
 delete mode 100644 drivers/gpu/drm/nouveau/nouveau_fbcon.c


signature.asc
Description: PGP signature


[Intel-gfx] [PULL] drm-misc-fixes

2023-01-04 Thread Maxime Ripard
Hi Dave, Daniel,

Here's this week drm-misc-fixes PR

Maxime

drm-misc-fixes-2023-01-05:
Several fixes to fix the error path of dma_buf_export, add a missing
structure declaration resulting in a compiler warning, fix the GEM
handle refcounting in panfrost, fix a corrupted image with AFBC on
meson, a memleak in virtio, improper plane width for imx, and a lockup
in drm_sched_entity_kill()
The following changes since commit 88603b6dc419445847923fcb7fe5080067a30f98:

  Linux 6.2-rc2 (2023-01-01 13:53:16 -0800)

are available in the Git repository at:

  git://anongit.freedesktop.org/drm/drm-misc tags/drm-misc-fixes-2023-01-05

for you to fetch changes up to 6949cfa42e10f2fdd2699ed4e34d9d4f392b:

  drm/scheduler: Fix lockup in drm_sched_entity_kill() (2023-01-03 14:49:59 
+0300)


Several fixes to fix the error path of dma_buf_export, add a missing
structure declaration resulting in a compiler warning, fix the GEM
handle refcounting in panfrost, fix a corrupted image with AFBC on
meson, a memleak in virtio, improper plane width for imx, and a lockup
in drm_sched_entity_kill()


Carlo Caione (1):
  drm/meson: Reduce the FIFO lines held when AFBC is not used

Christian König (1):
  dma-buf: fix dma_buf_export init order v2

Dmitry Osipenko (1):
  drm/scheduler: Fix lockup in drm_sched_entity_kill()

Ma Jun (1):
  drm/plane-helper: Add the missing declaration of drm_atomic_state

Maxime Ripard (1):
  Merge drm/drm-fixes into drm-misc-fixes

Philipp Zabel (1):
  drm/imx: ipuv3-plane: Fix overlay plane width

Steven Price (1):
  drm/panfrost: Fix GEM handle creation ref-counting

Xiu Jianfeng (1):
  drm/virtio: Fix memory leak in virtio_gpu_object_create()

 drivers/dma-buf/dma-buf-sysfs-stats.c|  7 +--
 drivers/dma-buf/dma-buf-sysfs-stats.h|  4 +-
 drivers/dma-buf/dma-buf.c| 82 +++-
 drivers/gpu/drm/imx/ipuv3-plane.c| 14 +++---
 drivers/gpu/drm/meson/meson_viu.c|  5 +-
 drivers/gpu/drm/panfrost/panfrost_drv.c  | 27 +++
 drivers/gpu/drm/panfrost/panfrost_gem.c  | 16 +--
 drivers/gpu/drm/panfrost/panfrost_gem.h  |  5 +-
 drivers/gpu/drm/scheduler/sched_entity.c |  2 +-
 drivers/gpu/drm/scheduler/sched_main.c   |  4 +-
 drivers/gpu/drm/virtio/virtgpu_object.c  |  6 ++-
 include/drm/drm_plane_helper.h   |  1 +
 12 files changed, 80 insertions(+), 93 deletions(-)


signature.asc
Description: PGP signature


[Intel-gfx] [PULL] drm-misc-next-fixes

2023-01-03 Thread Maxime Ripard
Hi Daniel, Dave,

Here's the drm-misc-next-fixes leftovers.

Maxime

drm-misc-next-fixes-2023-01-03:
The drm-misc-next-fixes leftovers. It addresses a bug in drm/scheduler
ending up causing a lockup, and reduces the stack usage of some drm/mm
kunit tests.
The following changes since commit b02897e56b4e1fa6445be695ce5d605bb098435c:

  Revert "drm/fb-helper: Perform damage handling in deferred-I/O helper" 
(2022-11-23 09:11:32 +0100)

are available in the Git repository at:

  git://anongit.freedesktop.org/drm/drm-misc tags/drm-misc-next-fixes-2023-01-03

for you to fetch changes up to 03dec92c4f788c54a7c01b40a018f601eb8a6c52:

  drm/scheduler: Fix lockup in drm_sched_entity_kill() (2023-01-02 17:45:18 
+0300)


The drm-misc-next-fixes leftovers. It addresses a bug in drm/scheduler
ending up causing a lockup, and reduces the stack usage of some drm/mm
kunit tests.


Arnd Bergmann (1):
  drm/tests: reduce drm_mm_test stack usage

Dmitry Osipenko (1):
  drm/scheduler: Fix lockup in drm_sched_entity_kill()

 drivers/gpu/drm/scheduler/sched_entity.c | 2 +-
 drivers/gpu/drm/scheduler/sched_main.c   | 4 ++--
 drivers/gpu/drm/tests/Makefile   | 2 ++
 drivers/gpu/drm/tests/drm_mm_test.c  | 6 +++---
 4 files changed, 8 insertions(+), 6 deletions(-)


signature.asc
Description: PGP signature


[Intel-gfx] [PULL] drm-misc-fixes

2022-12-22 Thread Maxime Ripard
Hi,

here's this week drm-misc-fixes PR

Maxime

drm-misc-fixes-2022-12-22:
One fix for a use-after-free in panfrost, one to fix the error handling in
dma_buf_export and one to fix a compile error with
drm_plane_helper_atomic_check missing a definition for drm_atomic_state
The following changes since commit c4252650a8c4770b669398fe7270ed8c94fc0eba:

  Merge tag 'drm-misc-fixes-2022-12-08' of 
git://anongit.freedesktop.org/drm/drm-misc into drm-fixes (2022-12-09 10:11:06 
+1000)

are available in the Git repository at:

  git://anongit.freedesktop.org/drm/drm-misc tags/drm-misc-fixes-2022-12-22

for you to fetch changes up to 4217c6ac817451d5116687f3cc6286220dc43d49:

  drm/panfrost: Fix GEM handle creation ref-counting (2022-12-21 15:04:42 +)


One fix for a use-after-free in panfrost, one to fix the error handling in
dma_buf_export and one to fix a compile error with
drm_plane_helper_atomic_check missing a definition for drm_atomic_state


Christian König (1):
  dma-buf: fix dma_buf_export init order v2

Ma Jun (1):
  drm/plane-helper: Add the missing declaration of drm_atomic_state

Steven Price (1):
  drm/panfrost: Fix GEM handle creation ref-counting

 drivers/dma-buf/dma-buf-sysfs-stats.c   |  7 +--
 drivers/dma-buf/dma-buf-sysfs-stats.h   |  4 +-
 drivers/dma-buf/dma-buf.c   | 84 +++--
 drivers/gpu/drm/panfrost/panfrost_drv.c | 27 +++
 drivers/gpu/drm/panfrost/panfrost_gem.c | 16 +--
 drivers/gpu/drm/panfrost/panfrost_gem.h |  5 +-
 include/drm/drm_plane_helper.h  |  1 +
 7 files changed, 64 insertions(+), 80 deletions(-)


signature.asc
Description: PGP signature


[Intel-gfx] [PULL] drm-misc-next-fixes

2022-12-08 Thread Maxime Ripard
Hi,

Here's this week drm-misc-next-fixes PR

All of those patches seems to have been applied to both drm-misc-next
and drm-misc-next-fixes and were part of the final drm-misc-next PR for
6.2.

So we shouldn't have any new patch per se, but it aligns all our
branches and fixes this odd situation.

Maxime

drm-misc-next-fixes-2022-12-08:
Some deferred-io and damage worker reworks revert and make a fb function
static
The following changes since commit 3d335a523b938a445a674be24d1dd5c7a4c86fb6:

  Merge tag 'drm-intel-next-2022-11-18' of 
git://anongit.freedesktop.org/drm/drm-intel into drm-next (2022-11-23 09:15:44 
+1000)

are available in the Git repository at:

  git://anongit.freedesktop.org/drm/drm-misc tags/drm-misc-next-fixes-2022-12-08

for you to fetch changes up to b02897e56b4e1fa6445be695ce5d605bb098435c:

  Revert "drm/fb-helper: Perform damage handling in deferred-I/O helper" 
(2022-11-23 09:11:32 +0100)


Some deferred-io and damage worker reworks revert and make a fb function
static


Thomas Zimmermann (6):
  Merge drm/drm-next into drm-misc-next-fixes
  Merge drm/drm-next into drm-misc-next-fixes
  fbdev: Make fb_modesetting_disabled() static inline
  Revert "drm/fb-helper: Remove damage worker"
  Revert "drm/fb-helper: Schedule deferred-I/O worker after writing to 
framebuffer"
  Revert "drm/fb-helper: Perform damage handling in deferred-I/O helper"

 drivers/gpu/drm/drm_fb_helper.c | 30 +-
 drivers/video/fbdev/core/fb_defio.c | 16 
 include/drm/drm_fb_helper.h |  2 ++
 include/linux/fb.h  |  3 +--
 4 files changed, 16 insertions(+), 35 deletions(-)


signature.asc
Description: PGP signature


Re: [Intel-gfx] [PULL] drm-misc-fixes

2022-11-30 Thread Maxime Ripard
Hi Maarten

On Wed, Nov 30, 2022 at 02:16:05PM +0100, Maarten Lankhorst wrote:
> A single fix to vmwgfx mks-guest-stats ioctl.
> I lost my internet connection when pushing the tag, so I put together this 
> mail
> manually. I hope you remember where drm-misc is hosted. :)

For reference, you can generate the mail content after the fact by using 
something like:

git request-pull drm/fixes drm-misc drm-misc-fixes-2022-11-30

Maxime


signature.asc
Description: PGP signature


Re: [Intel-gfx] [PATCH v10 00/19] drm: Analog TV Improvements

2022-11-24 Thread Maxime Ripard
On Mon, Nov 21, 2022 at 03:51:26PM +0100, Daniel Vetter wrote:
> On Thu, Nov 17, 2022 at 10:28:43AM +0100, Maxime Ripard wrote:
> > Hi,
> > 
> > Here's a series aiming at improving the command line named modes support,
> > and more importantly how we deal with all the analog TV variants.
> > 
> > The named modes support were initially introduced to allow to specify the
> > analog TV mode to be used.
> > 
> > However, this was causing multiple issues:
> > 
> >   * The mode name parsed on the command line was passed directly to the
> > driver, which had to figure out which mode it was suppose to match;
> > 
> >   * Figuring that out wasn't really easy, since the video= argument or what
> > the userspace might not even have a name in the first place, but
> > instead could have passed a mode with the same timings;
> > 
> >   * The fallback to matching on the timings was mostly working as long as
> > we were supporting one 525 lines (most likely NSTC) and one 625 lines
> > (PAL), but couldn't differentiate between two modes with the same
> > timings (NTSC vs PAL-M vs NSTC-J for example);
> > 
> >   * There was also some overlap with the tv mode property registered by
> > drm_mode_create_tv_properties(), but named modes weren't interacting
> > with that property at all.
> > 
> >   * Even though that property was generic, its possible values were
> > specific to each drivers, which made some generic support difficult.
> > 
> > Thus, I chose to tackle in multiple steps:
> > 
> >   * A new TV mode property was introduced, with generic values, each driver
> > reporting through a bitmask what standard it supports to the userspace;
> > 
> >   * This option was added to the command line parsing code to be able to
> > specify it on the kernel command line, and new atomic_check and reset
> > helpers were created to integrate properly into atomic KMS;
> > 
> >   * The named mode parsing code is now creating a proper display mode for
> > the given named mode, and the TV standard will thus be part of the
> > connector state;
> > 
> >   * Two drivers were converted and tested for now (vc4 and sun4i), with
> > some backward compatibility code to translate the old TV mode to the
> > new TV mode;
> > 
> > Unit tests were created along the way.
> > 
> > One can switch from NTSC to PAL now using (on vc4)
> > 
> > modetest -M vc4  -s 53:720x480i -w 53:'TV mode':1 # NTSC
> > modetest -M vc4  -s 53:720x576i -w 53:'TV mode':4 # PAL
> > 
> > Let me know what you think,
> > Maxime
> 
> Maxime asked me to drop an Ack-in-principle on this, and I'm not sure I
> have any useful input here with my utter lack of understanding for TV
> things (I never even had one in my entire life, that's how much I don't
> care). But it seems to check all the design boxes around solving annoying
> uapi/kms-config issues properly, so
> 
> Acked-in-principle-or-something-like-that-by: Daniel Vetter 
> 

Thanks!

I jumped the gun a bit too fast and forgot to amend the TV property
commit message before pushing it out.

For the record though, that property is usable through xrandr, xorg.conf
or any equivalent compositor mechanism

Maxime


signature.asc
Description: PGP signature


[Intel-gfx] [PULL] drm-misc-next

2022-11-23 Thread Maxime Ripard
Hi Daniel, Dave,

We might be fairly late for a drm-misc-next PR by now, but I chose to
send it anyway because we might have an -rc8, and this is almost
exclusively fixes that should go in anyway. This will be the last
drm-misc-next PR for this cycle

Maxime

drm-misc-next-2022-11-24:
drm-misc-next for 6.2:

UAPI Changes:

Cross-subsystem Changes:
- fbdev: Make fb_modesetting_disabled() static
- udmabuf: Add vmap and vunmap methods to udmabuf_ops

Core Changes:
- doc: make drm-uapi igt-tests more readable
- fb-helper: Revert of the damage worker removal
- fourcc: Add missing big-endian XRGB1555 and RGB565 formats
- gem-shmem: Fix for resource leakage in __drm_gem_shmem_create()
- scheduler: Fix lockup in drm_sched_entity_kill()

Driver Changes:
The following changes since commit 35c3a2d02f0dc153a5f2f304ba33e1436b6a8d8f:

  drm/tests: helpers: Add SPDX header (2022-11-17 09:25:38 +0100)

are available in the Git repository at:

  git://anongit.freedesktop.org/drm/drm-misc tags/drm-misc-next-2022-11-24

for you to fetch changes up to 6fb6c979ca628583d4d0c59a0f8ff977e581ecc0:

  drm/fourcc: Add missing big-endian XRGB1555 and RGB565 formats (2022-11-23 
20:34:46 +0100)


drm-misc-next for 6.2:

UAPI Changes:

Cross-subsystem Changes:
- fbdev: Make fb_modesetting_disabled() static
- udmabuf: Add vmap and vunmap methods to udmabuf_ops

Core Changes:
- doc: make drm-uapi igt-tests more readable
- fb-helper: Revert of the damage worker removal
- fourcc: Add missing big-endian XRGB1555 and RGB565 formats
- gem-shmem: Fix for resource leakage in __drm_gem_shmem_create()
- scheduler: Fix lockup in drm_sched_entity_kill()

Driver Changes:


ChunyouTang (1):
  drm/gem-shmem: When drm_gem_object_init failed, should release object

Dmitry Osipenko (1):
  drm/scheduler: Fix lockup in drm_sched_entity_kill()

Geert Uytterhoeven (1):
  drm/fourcc: Add missing big-endian XRGB1555 and RGB565 formats

Lukasz Wiecaszek (1):
  udmabuf: add vmap and vunmap methods to udmabuf_ops

Randy Dunlap (1):
  drm/doc: make drm-uapi igt-tests more readable

Shang XiaoJing (1):
  drm: Fix potential null-ptr-deref due to drmm_mode_config_init()

Thomas Zimmermann (4):
  fbdev: Make fb_modesetting_disabled() static inline
  Revert "drm/fb-helper: Remove damage worker"
  Revert "drm/fb-helper: Schedule deferred-I/O worker after writing to 
framebuffer"
  Revert "drm/fb-helper: Perform damage handling in deferred-I/O helper"

 Documentation/gpu/drm-uapi.rst   | 12 ++--
 drivers/dma-buf/udmabuf.c| 28 
 drivers/gpu/drm/drm_fb_helper.c  | 30 +-
 drivers/gpu/drm/drm_fourcc.c |  4 
 drivers/gpu/drm/drm_gem.c| 19 ---
 drivers/gpu/drm/drm_gem_shmem_helper.c   |  4 +++-
 drivers/gpu/drm/drm_mode_config.c|  8 +++-
 drivers/gpu/drm/scheduler/sched_entity.c |  2 +-
 drivers/gpu/drm/scheduler/sched_main.c   |  4 ++--
 drivers/video/fbdev/core/fb_defio.c  | 16 
 include/drm/drm_fb_helper.h  |  2 ++
 include/drm/drm_gem.h|  1 +
 include/linux/fb.h   |  3 +--
 13 files changed, 84 insertions(+), 49 deletions(-)


signature.asc
Description: PGP signature


Re: [Intel-gfx] linux-next: manual merge of the drm-misc tree with the origin tree

2022-11-18 Thread Maxime Ripard
On Thu, Nov 17, 2022 at 05:01:08PM -0700, Nathan Chancellor wrote:
> On Fri, Nov 18, 2022 at 09:06:36AM +1100, Stephen Rothwell wrote:
> > Hi Nathan,
> > 
> > On Thu, 17 Nov 2022 10:29:33 -0700 Nathan Chancellor  
> > wrote:
> > >
> > > This resolution is not quite right, as pointed out by clang:
> > > 
> > > drivers/gpu/drm/vc4/vc4_hdmi.c:351:14: error: variable 'vc4_hdmi' is 
> > > uninitialized when used here [-Werror,-Wuninitialized]
> > > mutex_lock(_hdmi->mutex);
> > > ^~~~
> > > ./include/linux/mutex.h:187:44: note: expanded from macro 'mutex_lock'
> > > #define mutex_lock(lock) mutex_lock_nested(lock, 0)
> > >^~~~
> > > drivers/gpu/drm/vc4/vc4_hdmi.c:322:27: note: initialize the variable 
> > > 'vc4_hdmi' to silence this warning
> > > struct vc4_hdmi *vc4_hdmi;
> > >  ^
> > >   = NULL
> > > 1 error generated.
> > > 
> > > Obviously, the assignment of vc4_hdmi should be before mutex_lock().
> > 
> > Thanks for pointing that out (silly me :-) ).  I have fixed up the
> > resolution for today.
> 
> Great, thank you so much! One less warning to worry about :)

I actually did the same conflict resolution in drm-tip. I've fixed it up
too, thanks for your report :)

Maxime


signature.asc
Description: PGP signature


Re: [Intel-gfx] [PATCH v10 18/19] drm/vc4: vec: Add support for more analog TV standards

2022-11-17 Thread Maxime Ripard
On Thu, Nov 17, 2022 at 04:49:28PM +0100, Mauro Carvalho Chehab wrote:
> On Thu, 17 Nov 2022 10:29:01 +0100
> Maxime Ripard  wrote:
> 
> > From: Mateusz Kwiatkowski 
> > 
> > Add support for the following composite output modes (all of them are
> > somewhat more obscure than the previously defined ones):
> > 
> > - NTSC_443 - NTSC-style signal with the chroma subcarrier shifted to
> >   4.43361875 MHz (the PAL subcarrier frequency). Never used for
> >   broadcasting, but sometimes used as a hack to play NTSC content in PAL
> >   regions (e.g. on VCRs).
> 
> > - PAL_N - PAL with alternative chroma subcarrier frequency,
> >   3.58205625 MHz. Used as a broadcast standard in Argentina, Paraguay
> >   and Uruguay to fit 576i50 with colour in 6 MHz channel raster.
> 
> That's not right. Argentina uses a different standard than Paraguay and
> Uruguai.
> 
> See, there are two variants of PAL/N. The original one and PAL/N' - also
> called PAL/NC or PAL/CN (Combination N). Some of the timings are 
> different on /NC variant.
> 
> As far as I'm aware, PAL/Nc is used in Argentina, while
> PAL/N is used in Paraguai and Uruguai, but I may be wrong on that,
> as it has been a long time since had to touch on this.
> 
> > - PAL60 - 480i60 signal with PAL-style color at normal European PAL
> >   frequency. Another non-standard, non-broadcast mode, used in similar
> >   contexts as NTSC_443. Some displays support one but not the other.
> 
> > - SECAM - French frequency-modulated analog color standard; also have
> >   been broadcast in Eastern Europe and various parts of Africa and Asia.
> >   Uses the same 576i50 timings as PAL.
> 
> This is also wrong. just like PAL, there are several variants of SECAM,
> one used in France, and a different one in France overseas and on
> previous France colonies in Africa and Asia. Eastern Europe also used
> different variants of SECAM.

And that's fine? Everything I did is supposed to be easy to extend if
and when needed, so if someone has some interest in providing support
for more standards, they are very welcome to do so.

I won't do it in this series though.

Maxime


signature.asc
Description: PGP signature


Re: [Intel-gfx] [PATCH v10 05/19] drm/connector: Add TV standard property

2022-11-17 Thread Maxime Ripard
On Thu, Nov 17, 2022 at 03:35:57PM +0100, Mauro Carvalho Chehab wrote:
> On Thu, 17 Nov 2022 10:28:48 +0100
> Maxime Ripard  wrote:
> 
> > The TV mode property has been around for a while now to select and get the
> > current TV mode output on an analog TV connector.
> > 
> > Despite that property name being generic, its content isn't and has been
> > driver-specific which makes it hard to build any generic behaviour on top
> > of it, both in kernel and user-space.
> > 
> > Let's create a new enum tv norm property, that can contain any of the
> > analog TV standards currently supported by kernel drivers. Each driver can
> > then pass in a bitmask of the modes it supports, and the property
> > creation function will filter out the modes not supported.
> > 
> > We'll then be able to phase out the older tv mode property.
> > 
> > Tested-by: Mateusz Kwiatkowski 
> > Signed-off-by: Maxime Ripard 
> > 
> > ---
> > Changes in v10:
> > - Fix checkpatch warning
> > 
> > Changes in v5:
> > - Create an analog TV properties documentation section, and document TV
> >   Mode there instead of the csv file
> > 
> > Changes in v4:
> > - Add property documentation to kms-properties.csv
> > - Fix documentation
> > ---
> >  Documentation/gpu/drm-kms.rst |   6 ++
> >  drivers/gpu/drm/drm_atomic_uapi.c |   4 ++
> >  drivers/gpu/drm/drm_connector.c   | 122 
> > +-
> >  include/drm/drm_connector.h   |  64 
> >  include/drm/drm_mode_config.h |   8 +++
> >  5 files changed, 203 insertions(+), 1 deletion(-)
> > 
> > diff --git a/Documentation/gpu/drm-kms.rst b/Documentation/gpu/drm-kms.rst
> > index b4377a545425..321f2f582c64 100644
> > --- a/Documentation/gpu/drm-kms.rst
> > +++ b/Documentation/gpu/drm-kms.rst
> > @@ -520,6 +520,12 @@ HDMI Specific Connector Properties
> >  .. kernel-doc:: drivers/gpu/drm/drm_connector.c
> > :doc: HDMI connector properties
> >  
> > +Analog TV Specific Connector Properties
> > +--
> > +
> > +.. kernel-doc:: drivers/gpu/drm/drm_connector.c
> > +   :doc: Analog TV Connector Properties
> > +
> >  Standard CRTC Properties
> >  
> >  
> > diff --git a/drivers/gpu/drm/drm_atomic_uapi.c 
> > b/drivers/gpu/drm/drm_atomic_uapi.c
> > index 7f2b9a07fbdf..d867e7f9f2cd 100644
> > --- a/drivers/gpu/drm/drm_atomic_uapi.c
> > +++ b/drivers/gpu/drm/drm_atomic_uapi.c
> > @@ -700,6 +700,8 @@ static int drm_atomic_connector_set_property(struct 
> > drm_connector *connector,
> > state->tv.margins.bottom = val;
> > } else if (property == config->legacy_tv_mode_property) {
> > state->tv.legacy_mode = val;
> > +   } else if (property == config->tv_mode_property) {
> > +   state->tv.mode = val;
> > } else if (property == config->tv_brightness_property) {
> > state->tv.brightness = val;
> > } else if (property == config->tv_contrast_property) {
> > @@ -810,6 +812,8 @@ drm_atomic_connector_get_property(struct drm_connector 
> > *connector,
> > *val = state->tv.margins.bottom;
> > } else if (property == config->legacy_tv_mode_property) {
> > *val = state->tv.legacy_mode;
> > +   } else if (property == config->tv_mode_property) {
> > +   *val = state->tv.mode;
> > } else if (property == config->tv_brightness_property) {
> > *val = state->tv.brightness;
> > } else if (property == config->tv_contrast_property) {
> > diff --git a/drivers/gpu/drm/drm_connector.c 
> > b/drivers/gpu/drm/drm_connector.c
> > index 06e737ed15f5..07d449736956 100644
> > --- a/drivers/gpu/drm/drm_connector.c
> > +++ b/drivers/gpu/drm/drm_connector.c
> > @@ -984,6 +984,17 @@ static const struct drm_prop_enum_list 
> > drm_dvi_i_subconnector_enum_list[] = {
> >  DRM_ENUM_NAME_FN(drm_get_dvi_i_subconnector_name,
> >  drm_dvi_i_subconnector_enum_list)
> >  
> > +static const struct drm_prop_enum_list drm_tv_mode_enum_list[] = {
> > +   { DRM_MODE_TV_MODE_NTSC, "NTSC" },
> > +   { DRM_MODE_TV_MODE_NTSC_443, "NTSC-443" },
> > +   { DRM_MODE_TV_MODE_NTSC_J, "NTSC-J" },
> > +   { DRM_MODE_TV_MODE_PAL, "PAL" },
> > +   { DRM_MODE_TV_MODE_PAL_M, "PAL-M" },
> > +   { DRM_MODE_TV_MODE_PAL_N, "PAL-N" },
> > +   { DRM_MODE

  1   2   3   4   5   6   7   >