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]
Date:   Sun, 6 Dec 2020 09:46:43 +0800
From:   tanhuazhong <tanhuazhong@...wei.com>
To:     Jakub Kicinski <kuba@...nel.org>
CC:     <davem@...emloft.net>, <netdev@...r.kernel.org>,
        <linux-kernel@...r.kernel.org>, <salil.mehta@...wei.com>,
        <yisen.zhuang@...wei.com>, <linuxarm@...wei.com>,
        <huangdaode@...wei.com>, Jian Shen <shenjian15@...wei.com>
Subject: Re: [PATCH net-next 2/3] net: hns3: add priv flags support to switch
 limit promisc mode



On 2020/12/5 10:24, Jakub Kicinski wrote:
> On Thu, 3 Dec 2020 20:18:55 +0800 Huazhong Tan wrote:
>> @@ -224,6 +224,7 @@ static int hclge_map_unmap_ring_to_vf_vector(struct hclge_vport *vport, bool en,
>>   static int hclge_set_vf_promisc_mode(struct hclge_vport *vport,
>>   				     struct hclge_mbx_vf_to_pf_cmd *req)
>>   {
>> +	struct hnae3_handle *handle = &vport->nic;
>>   	bool en_bc = req->msg.en_bc ? true : false;
>>   	bool en_uc = req->msg.en_uc ? true : false;
>>   	bool en_mc = req->msg.en_mc ? true : false;
> 
> Please order variable lines longest to shortest.

will fix it, thanks.

> 
>> @@ -1154,6 +1158,8 @@ static int hclgevf_cmd_set_promisc_mode(struct hclgevf_dev *hdev,
>>   	send_msg.en_bc = en_bc_pmc ? 1 : 0;
>>   	send_msg.en_uc = en_uc_pmc ? 1 : 0;
>>   	send_msg.en_mc = en_mc_pmc ? 1 : 0;
>> +	send_msg.en_limit_promisc =
>> +	test_bit(HNAE3_PFLAG_LIMIT_PROMISC_ENABLE, &handle->priv_flags) ? 1 : 0;
> 
> The continuation line should be indented more than the first line.

yes, will fix it.

> 
> I suggest you rename HNAE3_PFLAG_LIMIT_PROMISC_ENABLE to
> HNAE3_PFLAG_LIMIT_PROMISC, the _ENABLE doesn't add much
> to the meaning. That way the lines will get shorter.
> 

ok, thanks.

> .
> 

Powered by blists - more mailing lists