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  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]
Date:   Tue, 21 Jul 2020 07:09:53 +0000
From:   "Sriram Krishnan (srirakr2)" <>
To:     David Miller <>
CC:     "" <>,
        "" <>,
        "" <>,
        "" <>,
        "Malcolm Bumgardner (mbumgard)" <>,
        "Umesha G M (ugm)" <>,
        "Niranjan M M (nimm)" <>,
        "xe-linux-external(mailer list)" <>,
        "" <>,
        "" <>,
        "" <>,
        "" <>
Subject: Re: [PATCH v3] net: hyperv: add support for vlans in netvsc driver

On 21/07/20, 4:57 AM, "David Miller" <> wrote:

    From: Sriram Krishnan <>
    Date: Mon, 20 Jul 2020 22:15:51 +0530

    > +	if (skb->protocol == htons(ETH_P_8021Q)) {
    > +		u16 vlan_tci = 0;
    > +		skb_reset_mac_header(skb);

   > Please place an empty line between basic block local variable declarations
   > and actual code.

    > +				netdev_err(net,"Pop vlan err %x\n",pop_err);

    > A space is necessary before "pop_err".

Consolidated list of comments addressed:
> 1. Blank line between declaration and code.

> 2. Error handling is different than other parts of this code.
>   probably just need a goto drop on error.

> It seems like you are putting into message, then driver is putting
> it into meta-data in next code block. Maybe it should be combined?
Not done
This was on purpose. Merging the two code blocks might break existing functionality.
There could be other modes where the packet arrives with 802.1q already in the
Skb and the skb->protocol needn’t be 802.1q.

> packet->total_bytes should be updated too.
Not done.
The total_bytes needs be the total length of packet after the host OS adds the 802.1q header back in
before tx. Updating the total_bytes to -= VLAN_HEADER will lead to packet drop in the Host OS driver.

> Also netvsc already supports vlan in "regular" cases. Please be more specific in the subject.
> Suggested subject: hv_netvsc: add support for vlans in AF_PACKET mode

> A space is necessary before "pop_err".

Uploaded patch v4

Powered by blists - more mailing lists