dri-devel.lists.freedesktop.org archive mirror
 help / color / mirror / Atom feed
From: Stanislaw Gruszka <stanislaw.gruszka@linux.intel.com>
To: Randy Dunlap <rdunlap@infradead.org>
Cc: Tvrtko Ursulin <tvrtko.ursulin@linux.intel.com>,
	Jiho Chu <jiho.chu@samsung.com>,
	Jeffrey Hugo <quic_jhugo@quicinc.com>,
	Thomas Zimmermann <tzimmermann@suse.de>,
	Arnd Bergmann <arnd@arndb.de>,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	Oded Gabbay <ogabbay@kernel.org>,
	Yuji Ishikawa <yuji2.ishikawa@toshiba.co.jp>,
	linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org,
	Christoph Hellwig <hch@infradead.org>,
	Jagan Teki <jagan@amarulasolutions.com>,
	Jacek Lawrynowicz <jacek.lawrynowicz@linux.intel.com>,
	John Hubbard <jhubbard@nvidia.com>,
	Alex Deucher <alexander.deucher@amd.com>,
	stanislaw.gruszka@intel.com, Kevin Hilman <khilman@baylibre.com>,
	Maciej Kwapulinski <maciej.kwapulinski@linux.intel.com>,
	Jason Gunthorpe <jgg@nvidia.com>
Subject: Re: [RFC PATCH v2 1/3] drivers/accel: define kconfig and register a new major
Date: Fri, 4 Nov 2022 08:23:32 +0100	[thread overview]
Message-ID: <20221104072332.GA3149018@linux.intel.com> (raw)
In-Reply-To: <d5630f32-208a-77d2-91ed-58ef526ed086@infradead.org>

On Thu, Nov 03, 2022 at 04:01:08PM -0700, Randy Dunlap wrote:
> >>> Module name if "M" is chosen?
> >> Will add
> > So, unfortunately, the path of doing accel as a kernel module won't
> > work cleanly (Thanks stanislaw for pointing this out to me).
> > The reason is the circular dependency between drm and accel. drm calls
> > accel exported symbols during init and when devices are registering
> > (all the minor handling), and accel calls drm exported symbols because
> > I don't want to duplicate the entire drm core code.
> 
> But DRM is a tristate symbol, so during drm init (loadable module), couldn't
> it call accel init code (loadable module)?
> 
> Or are you saying that they only work together if both of them are builtin?

Yes, with current state of the patches, we can not build code as modules.
There are symbols in accel that are from drm and we use accel symbols
in drm. This could be fixed by separating symbols accel requires in 
separate module i.e. drm_file_helper.ko, however Oded proposed to make
CONFIG_ACCEL compile option for DRM and all accel code will be
build in drm.ko . I think that ok, since accel is not big. 

Regards
Stanislaw


  reply	other threads:[~2022-11-04  7:23 UTC|newest]

Thread overview: 33+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-11-02 20:34 [RFC PATCH v2 0/3] new subsystem for compute accelerator devices Oded Gabbay
2022-11-02 20:34 ` [RFC PATCH v2 1/3] drivers/accel: define kconfig and register a new major Oded Gabbay
2022-11-02 21:04   ` Jeffrey Hugo
2022-11-03 13:28     ` Oded Gabbay
2022-11-02 22:58   ` Randy Dunlap
2022-11-03 13:29     ` Oded Gabbay
2022-11-03  0:32   ` Greg Kroah-Hartman
2022-11-03 13:31     ` Oded Gabbay
2022-11-03 20:39       ` Oded Gabbay
2022-11-03 23:01         ` Randy Dunlap
2022-11-04  7:23           ` Stanislaw Gruszka [this message]
2022-11-07 12:56         ` Jason Gunthorpe
2022-11-07 13:01           ` Oded Gabbay
2022-11-07 13:10             ` Jason Gunthorpe
2022-11-07 13:25               ` Stanislaw Gruszka
2022-11-07 14:02               ` Oded Gabbay
2022-11-07 14:10                 ` Jason Gunthorpe
2022-11-07 15:53                   ` Oded Gabbay
2022-11-07 16:30                     ` Jason Gunthorpe
2022-11-07 19:27                       ` Oded Gabbay
2022-11-07 20:33                       ` Dave Airlie
2022-11-08 12:28                         ` Jason Gunthorpe
2022-11-09  7:22                           ` Dave Airlie
2022-11-07 20:18               ` Dave Airlie
2022-11-02 20:34 ` [RFC PATCH v2 2/3] accel: add dedicated minor for accelerator devices Oded Gabbay
2022-11-02 21:17   ` Jeffrey Hugo
2022-11-06 10:51     ` Oded Gabbay
2022-11-03  5:25   ` Jiho Chu
2022-11-06 10:54     ` Oded Gabbay
2022-11-06 14:15       ` Oded Gabbay
2022-11-02 20:34 ` [RFC PATCH v2 3/3] drm: initialize accel framework Oded Gabbay
2022-11-02 21:30   ` Jeffrey Hugo
2022-11-06 10:55     ` Oded Gabbay

Reply instructions:

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

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

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

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

  git send-email \
    --in-reply-to=20221104072332.GA3149018@linux.intel.com \
    --to=stanislaw.gruszka@linux.intel.com \
    --cc=alexander.deucher@amd.com \
    --cc=arnd@arndb.de \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=hch@infradead.org \
    --cc=jacek.lawrynowicz@linux.intel.com \
    --cc=jagan@amarulasolutions.com \
    --cc=jgg@nvidia.com \
    --cc=jhubbard@nvidia.com \
    --cc=jiho.chu@samsung.com \
    --cc=khilman@baylibre.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=maciej.kwapulinski@linux.intel.com \
    --cc=ogabbay@kernel.org \
    --cc=quic_jhugo@quicinc.com \
    --cc=rdunlap@infradead.org \
    --cc=stanislaw.gruszka@intel.com \
    --cc=tvrtko.ursulin@linux.intel.com \
    --cc=tzimmermann@suse.de \
    --cc=yuji2.ishikawa@toshiba.co.jp \
    /path/to/YOUR_REPLY

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

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