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] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAMZ6RqLZXyiW0CZg0spocXie+2-cnyS0Ai_9qTA6UiEHdH99bA@mail.gmail.com>
Date:   Fri, 13 May 2022 21:14:53 +0900
From:   Vincent Mailhol <vincent.mailhol@...il.com>
To:     Marc Kleine-Budde <mkl@...gutronix.de>
Cc:     Max Staudt <max@...as.org>,
        Wolfgang Grandegger <wg@...ndegger.com>,
        linux-can@...r.kernel.org,
        Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
        Oliver Neukum <oneukum@...e.com>, linux-kernel@...r.kernel.org
Subject: Re: [PATCH v6] can, tty: can327 CAN/ldisc driver for ELM327 based
 OBD-II adapters

On Fri 13 May 2022 at 20:52, Marc Kleine-Budde <mkl@...gutronix.de> wrote:
> On 13.05.2022 11:38:31, Vincent Mailhol wrote:
> > > +
> > > +       /* We shouldn't get here after a hardware fault:
> > > +        * can_bus_off() calls netif_carrier_off()
> > > +        */
> > > +       WARN_ON_ONCE(elm->uart_side_failure);
> > > +
> > > +       if (!elm->tty ||
> > > +           elm->uart_side_failure ||
> > > +           elm->can.ctrlmode & CAN_CTRLMODE_LISTENONLY) {
> >
> > Can the xmit function get called when CAN_CTRLMODE_LISTENONLY is on?
>
> I think yes. You can skip the whole CAN stack by injecting CAN frames in
> the kernel via the packet socket. Maybe we should add a check to
> can_dropped_invalid_skb().

Ack. Most of the drivers do not check for it (my doesn't). So better
to put it in can_dropped_invalid_skb().
I can do the patch for this.

And also noted for your previous comment on lockdep_assert_held().
@Max: please ignore this particular remark.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ