All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Christian König" <ckoenig.leichtzumerken@gmail.com>
To: Thomas Zimmermann <tzimmermann@suse.de>
Cc: Alex Deucher <Alexander.Deucher@amd.com>,
	"Slivka, Danijel" <Danijel.Slivka@amd.com>,
	dri-devel <dri-devel@lists.freedesktop.org>,
	"Sharma, Shashank" <Shashank.Sharma@amd.com>
Subject: Amdgpu module is references even after unbinding the vtcon
Date: Tue, 24 Jan 2023 15:12:32 +0100	[thread overview]
Message-ID: <c5001553-6c71-c7ff-36aa-c4712bda0abf@gmail.com> (raw)

Hi Thomas,

we ran into a problem with the general fbcon/fbdev implementation and 
though that you might have some idea.

What happens is the following:
1. We load amdgpu and get our normal fbcon.
2. fbcon allocates a dump BO as backing store for the console.
3. GDM/X/Applications start, new framebuffers are created BOs imported, 
exported etc...
4. Somehow X or GDM iterated over all the framebuffer objects the 
kernels knows about and export them as DMA-buf.
5. Application/X/GDM are stopped, handles closed, framebuffers released 
etc...
6. We unbind vtcon.

At this point the amdgpu module usually has a reference count of 0 and 
can be unloaded, but since GDM/X/Whoever iterated over all the known 
framebuffers and exported them as DMA-buf (for whatever reason idk) we 
now still have an exported DMA-buf and with it a reference to the module.

Any idea how we could prevent that?

Thanks,
Christian.

             reply	other threads:[~2023-01-24 14:12 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-01-24 14:12 Christian König [this message]
2023-01-24 16:15 ` Amdgpu module is references even after unbinding the vtcon Thomas Zimmermann
2023-01-24 16:36   ` Alex Deucher
2023-01-24 17:35     ` Thomas Zimmermann
2023-01-25  6:49   ` Christian König
2023-01-25 19:47 ` Thomas Zimmermann
2023-01-26  9:49   ` Slivka, Danijel
2023-01-26 12:20     ` Christian König
2023-01-26 13:44       ` Slivka, Danijel
2023-01-26 14:11         ` Christian König
2023-01-26 14:13           ` Sharma, Shashank
2023-01-26 14:26             ` Christian König
2023-01-31 10:00           ` Slivka, Danijel
2023-01-26 12:40     ` Thomas Zimmermann
2023-01-26 12:45       ` Christian König
2023-01-26 12:54         ` Thomas Zimmermann

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=c5001553-6c71-c7ff-36aa-c4712bda0abf@gmail.com \
    --to=ckoenig.leichtzumerken@gmail.com \
    --cc=Alexander.Deucher@amd.com \
    --cc=Danijel.Slivka@amd.com \
    --cc=Shashank.Sharma@amd.com \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=tzimmermann@suse.de \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.