Subject: Re: [PATCH net v2] net: atm: Fix use-after-free bug in atm_dev_register()

From: Jakub Kicinski <[email-masked]>
Date: Wed, 14 Dec 2022 08:43:58 -0800

On Wed, 14 Dec 2022 09:51:09 +0200 Leon Romanovsky wrote:
> > Also atm_dev_register() still frees the dev on atm_register_sysfs()
> > failure, is that okay?  
> 
> Yes, the kernel panic points that class_dev (not dev) had use-after-free.

How is that possible? "class_dev" is embedded in dev (struct atm_dev).