We've discussed a bit how to get the gem/gt team better integrated and collaborate more with the wider community and agreed to the following:
- all gem/gt patches are reviewed on dri-devel for now. That's overkill, but in the past there was definitely too little of that.
- i915-gem folks are encouraged to cross review core patches from other teams
- big features (especially uapi changes) need to be discussed in an rfc patch that documents the interface and big picture design, before we get lost in the details of the code
- Also a rough TODO (can be refined as we go ofc) to get gem/gt back on track, like we've e.g. done with DAL/DC to get that in shape.
v2: - add dma_fence annotations (Dave) - tasklet helpers (Jani on irc)
There was also a discussion about moving these into gitlab issues, or gitlab issues as additional discussion place at least. For now it's just the TODO file
Cc: Jani Nikula jani.nikula@linux.intel.com Cc: Joonas Lahtinen joonas.lahtinen@linux.intel.com Cc: Rodrigo Vivi rodrigo.vivi@intel.com Cc: Jason Ekstrand jason@jlekstrand.net Cc: Dave Airlie airlied@redhat.com Acked-by: Dave Airlie airlied@redhat.com Acked-by: Rodrigo Vivi rodrigo.vivi@intel.com Signed-off-by: Daniel Vetter daniel.vetter@intel.com --- drivers/gpu/drm/i915/TODO.txt | 41 +++++++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) create mode 100644 drivers/gpu/drm/i915/TODO.txt
diff --git a/drivers/gpu/drm/i915/TODO.txt b/drivers/gpu/drm/i915/TODO.txt new file mode 100644 index 000000000000..81a82c9c203f --- /dev/null +++ b/drivers/gpu/drm/i915/TODO.txt @@ -0,0 +1,41 @@ +gem/gt TODO items +----------------- + +- For discrete memory manager, merge enough dg1 to be able to refactor it to + TTM. Then land pci ids (just in case that turns up an uapi problem). TTM has + improved a lot the past 2 years, there's no reason anymore not to use it. + +- Come up with a plan what to do with drm/scheduler and how to get there. + +- Roll out dma_fence critical section annotations. + +- There's a lot of complexity added past few years to make relocations faster. + That doesn't make sense given hw and gpu apis moved away from this model years + ago: + 1. Land a modern pre-bound uapi like VM_BIND + 2. Any complexity added in this area past few years which can't be justified + with VM_BIND using userspace should be removed. Looking at amdgpu dma_resv on + the bo and vm, plus some lru locks is all that needed. No complex rcu, + refcounts, caching, ... on everything. + This is the matching task on the vm side compared to ttm/dma_resv on the + backing storage side. + +- i915_sw_fence seems to be the main structure for the i915-gem dma_fence model. + How-to-dma_fence is core and drivers really shouldn't build their own world + here, treating everything else as a fixed platform. i915_sw_fence concepts + should be moved to dma_fence, drm/scheduler or atomic commit helpers. Or + removed if dri-devel consensus is that it's not a good idea. Once that's done + maybe even remove it if there's nothing left. + +Smaller things: +- i915_utils.h needs to be moved to the right places. + +- dma_fence_work should be in drivers/dma-buf + +- i915_mm.c should be moved to the right places. Some of the helpers also look a + bit fishy: + + https://lore.kernel.org/linux-mm/20210301083320.943079-1-hch@lst.de/ + +- tasklet helpers in i915_gem.h also look a bit misplaced and should + probably be moved to tasklet headers.
Motivated by the pre-review process for i915 gem/gt features, but probably useful in general for complex stuff.
v2: Add reminder to not forget userspace projects in the discussion (Simon, Jason)
Cc: Simon Ser contact@emersion.fr Cc: Jani Nikula jani.nikula@linux.intel.com Cc: Joonas Lahtinen joonas.lahtinen@linux.intel.com Cc: Rodrigo Vivi rodrigo.vivi@intel.com Cc: Jason Ekstrand jason@jlekstrand.net Cc: Dave Airlie airlied@redhat.com Acked-by: Rodrigo Vivi rodrigo.vivi@intel.com Acked-by: Dave Airlie airlied@redhat.com Signed-off-by: Daniel Vetter daniel.vetter@intel.com --- Documentation/gpu/index.rst | 1 + Documentation/gpu/rfc.rst | 17 +++++++++++++++++ 2 files changed, 18 insertions(+) create mode 100644 Documentation/gpu/rfc.rst
diff --git a/Documentation/gpu/index.rst b/Documentation/gpu/index.rst index c9a51e3bfb5a..df58cb826d68 100644 --- a/Documentation/gpu/index.rst +++ b/Documentation/gpu/index.rst @@ -16,6 +16,7 @@ Linux GPU Driver Developer's Guide vga-switcheroo vgaarbiter todo + rfc
.. only:: subproject and html
diff --git a/Documentation/gpu/rfc.rst b/Documentation/gpu/rfc.rst new file mode 100644 index 000000000000..a8621f7dab8b --- /dev/null +++ b/Documentation/gpu/rfc.rst @@ -0,0 +1,17 @@ +=============== +GPU RFC Section +=============== + +For complex work, especially new uapi, it is often good to nail the high level +design issues before getting lost in the code details. This section is meant to +host such documentation: + +* Each RFC should be a section in this file, explaining the goal and main design + considerations. Especially for uapi make sure you Cc: all relevant project + mailing lists and involved people outside of dri-devel. + +* For uapi structures add a file to this directory with and then pull the + kerneldoc in like with real uapi headers. + +* Once the code has landed move all the documentation to the right places in + the main core, helper or driver sections.
Acked-by: Jason Ekstrand jason@jlekstrand.net
On March 24, 2021 16:10:48 Daniel Vetter daniel.vetter@ffwll.ch wrote:
Motivated by the pre-review process for i915 gem/gt features, but probably useful in general for complex stuff.
v2: Add reminder to not forget userspace projects in the discussion (Simon, Jason)
Cc: Simon Ser contact@emersion.fr Cc: Jani Nikula jani.nikula@linux.intel.com Cc: Joonas Lahtinen joonas.lahtinen@linux.intel.com Cc: Rodrigo Vivi rodrigo.vivi@intel.com Cc: Jason Ekstrand jason@jlekstrand.net Cc: Dave Airlie airlied@redhat.com Acked-by: Rodrigo Vivi rodrigo.vivi@intel.com Acked-by: Dave Airlie airlied@redhat.com Signed-off-by: Daniel Vetter daniel.vetter@intel.com
Documentation/gpu/index.rst | 1 + Documentation/gpu/rfc.rst | 17 +++++++++++++++++ 2 files changed, 18 insertions(+) create mode 100644 Documentation/gpu/rfc.rst
diff --git a/Documentation/gpu/index.rst b/Documentation/gpu/index.rst index c9a51e3bfb5a..df58cb826d68 100644 --- a/Documentation/gpu/index.rst +++ b/Documentation/gpu/index.rst @@ -16,6 +16,7 @@ Linux GPU Driver Developer's Guide vga-switcheroo vgaarbiter todo
- rfc
.. only:: subproject and html
diff --git a/Documentation/gpu/rfc.rst b/Documentation/gpu/rfc.rst new file mode 100644 index 000000000000..a8621f7dab8b --- /dev/null +++ b/Documentation/gpu/rfc.rst @@ -0,0 +1,17 @@ +=============== +GPU RFC Section +===============
+For complex work, especially new uapi, it is often good to nail the high level +design issues before getting lost in the code details. This section is meant to +host such documentation:
+* Each RFC should be a section in this file, explaining the goal and main design
- considerations. Especially for uapi make sure you Cc: all relevant project
- mailing lists and involved people outside of dri-devel.
+* For uapi structures add a file to this directory with and then pull the
- kerneldoc in like with real uapi headers.
+* Once the code has landed move all the documentation to the right places in
- the main core, helper or driver sections.
-- 2.31.0
Acked-by: Simon Ser contact@emersion.fr
Motivated by the pre-review process for i915 gem/gt features, but probably useful in general for complex stuff.
v2: Add reminder to not forget userspace projects in the discussion (Simon, Jason)
v3: Actually put this into a folder, so we have it all (.rst files and headers for kerneldoc) contained somewhere separate (Jason)
Cc: Simon Ser contact@emersion.fr Cc: Jani Nikula jani.nikula@linux.intel.com Cc: Joonas Lahtinen joonas.lahtinen@linux.intel.com Cc: Rodrigo Vivi rodrigo.vivi@intel.com Cc: Jason Ekstrand jason@jlekstrand.net Cc: Dave Airlie airlied@redhat.com Acked-by: Jason Ekstrand jason@jlekstrand.net Acked-by: Simon Ser contact@emersion.fr Acked-by: Rodrigo Vivi rodrigo.vivi@intel.com Acked-by: Dave Airlie airlied@redhat.com Signed-off-by: Daniel Vetter daniel.vetter@intel.com --- Documentation/gpu/index.rst | 1 + Documentation/gpu/rfc/index.rst | 17 +++++++++++++++++ 2 files changed, 18 insertions(+) create mode 100644 Documentation/gpu/rfc/index.rst
diff --git a/Documentation/gpu/index.rst b/Documentation/gpu/index.rst index c9a51e3bfb5a..ec4bc72438e4 100644 --- a/Documentation/gpu/index.rst +++ b/Documentation/gpu/index.rst @@ -16,6 +16,7 @@ Linux GPU Driver Developer's Guide vga-switcheroo vgaarbiter todo + rfc/index
.. only:: subproject and html
diff --git a/Documentation/gpu/rfc/index.rst b/Documentation/gpu/rfc/index.rst new file mode 100644 index 000000000000..a8621f7dab8b --- /dev/null +++ b/Documentation/gpu/rfc/index.rst @@ -0,0 +1,17 @@ +=============== +GPU RFC Section +=============== + +For complex work, especially new uapi, it is often good to nail the high level +design issues before getting lost in the code details. This section is meant to +host such documentation: + +* Each RFC should be a section in this file, explaining the goal and main design + considerations. Especially for uapi make sure you Cc: all relevant project + mailing lists and involved people outside of dri-devel. + +* For uapi structures add a file to this directory with and then pull the + kerneldoc in like with real uapi headers. + +* Once the code has landed move all the documentation to the right places in + the main core, helper or driver sections.
On Thu, Mar 25, 2021 at 11:58:59PM +0100, Daniel Vetter wrote:
Motivated by the pre-review process for i915 gem/gt features, but probably useful in general for complex stuff.
v2: Add reminder to not forget userspace projects in the discussion (Simon, Jason)
v3: Actually put this into a folder, so we have it all (.rst files and headers for kerneldoc) contained somewhere separate (Jason)
Cc: Simon Ser contact@emersion.fr Cc: Jani Nikula jani.nikula@linux.intel.com Cc: Joonas Lahtinen joonas.lahtinen@linux.intel.com Cc: Rodrigo Vivi rodrigo.vivi@intel.com Cc: Jason Ekstrand jason@jlekstrand.net Cc: Dave Airlie airlied@redhat.com Acked-by: Jason Ekstrand jason@jlekstrand.net Acked-by: Simon Ser contact@emersion.fr Acked-by: Rodrigo Vivi rodrigo.vivi@intel.com Acked-by: Dave Airlie airlied@redhat.com Signed-off-by: Daniel Vetter daniel.vetter@intel.com
Smashed both patches into my topic branch that I'll send to Dave later today. -Daniel
Documentation/gpu/index.rst | 1 + Documentation/gpu/rfc/index.rst | 17 +++++++++++++++++ 2 files changed, 18 insertions(+) create mode 100644 Documentation/gpu/rfc/index.rst
diff --git a/Documentation/gpu/index.rst b/Documentation/gpu/index.rst index c9a51e3bfb5a..ec4bc72438e4 100644 --- a/Documentation/gpu/index.rst +++ b/Documentation/gpu/index.rst @@ -16,6 +16,7 @@ Linux GPU Driver Developer's Guide vga-switcheroo vgaarbiter todo
- rfc/index
.. only:: subproject and html
diff --git a/Documentation/gpu/rfc/index.rst b/Documentation/gpu/rfc/index.rst new file mode 100644 index 000000000000..a8621f7dab8b --- /dev/null +++ b/Documentation/gpu/rfc/index.rst @@ -0,0 +1,17 @@ +=============== +GPU RFC Section +===============
+For complex work, especially new uapi, it is often good to nail the high level +design issues before getting lost in the code details. This section is meant to +host such documentation:
+* Each RFC should be a section in this file, explaining the goal and main design
- considerations. Especially for uapi make sure you Cc: all relevant project
- mailing lists and involved people outside of dri-devel.
+* For uapi structures add a file to this directory with and then pull the
- kerneldoc in like with real uapi headers.
+* Once the code has landed move all the documentation to the right places in
- the main core, helper or driver sections.
-- 2.31.0
dri-devel@lists.freedesktop.org