lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:   Tue, 03 Dec 2019 11:28:03 -0800 (PST)
From:   David Miller <davem@...emloft.net>
To:     olteanv@...il.com
Cc:     richardcochran@...il.com, andrew@...n.ch, f.fainelli@...il.com,
        vivien.didelot@...il.com, claudiu.manoil@....com,
        alexandru.marginean@....com, xiaoliang.yang_1@....com,
        yangbo.lu@....com, netdev@...r.kernel.org,
        alexandre.belloni@...tlin.com, UNGLinuxDriver@...rochip.com,
        vladimir.oltean@....com, antoine.tenart@...tlin.com
Subject: Re: [PATCH v3 net] net: mscc: ocelot: unregister the PTP clock on
 deinit

From: Vladimir Oltean <olteanv@...il.com>
Date: Tue,  3 Dec 2019 17:45:35 +0200

> From: Vladimir Oltean <vladimir.oltean@....com>
> 
> Currently a switch driver deinit frees the regmaps, but the PTP clock is
> still out there, available to user space via /dev/ptpN. Any PTP
> operation is a ticking time bomb, since it will attempt to use the freed
> regmaps and thus trigger kernel panics:
 ...
> And now that ocelot->ptp_clock is checked at exit, prevent a potential
> error where ptp_clock_register returned a pointer-encoded error, which
> we are keeping in the ocelot private data structure. So now,
> ocelot->ptp_clock is now either NULL or a valid pointer.
> 
> Fixes: 4e3b0468e6d7 ("net: mscc: PTP Hardware Clock (PHC) support")
> Cc: Antoine Tenart <antoine.tenart@...tlin.com>
> Reviewed-by: Florian Fainelli <f.fainelli@...il.com>
> Signed-off-by: Vladimir Oltean <vladimir.oltean@....com>

Applied and queued up for v5.4 -stable, thanks.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ