Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1674979

Re: [PATCH] scsi: hisi_sas: redefine hisi_sas_phy.phy_type as u32

From "Martin K. Petersen" <martin.petersen@oracle.com>
Newsgroups linux.kernel
Subject Re: [PATCH] scsi: hisi_sas: redefine hisi_sas_phy.phy_type as u32
Date 2017-06-26 19:50 +0200
Message-ID <tWGj8-5mb-17@gated-at.bofh.it> (permalink)
References <tWyYi-I2-25@gated-at.bofh.it>
Organization Oracle Corporation

Show all headers | View raw


John,

> Element phy_type is a bitmask and it only ever has 2 bits possibly
> set, and it is overkill to define as a u64, so redefine as a u32.
>
> This change resolves static code check complaint that "phy->phy_type
> &= ~PORT_TYPE_SAS;" would unintentionally clear the high 32 bits as
> well.
>
> Structure hisi_sas_phy is also reordered to ensure packing efficiency.

Applied to 4.13/scsi-queue, thanks!

-- 
Martin K. Petersen	Oracle Linux Engineering

Back to linux.kernel | Previous | NextPrevious in thread | Find similar | Unroll thread


Thread

[PATCH] scsi: hisi_sas: redefine hisi_sas_phy.phy_type as u32 John Garry <john.garry@huawei.com> - 2017-06-26 12:00 +0200
  Re: [PATCH] scsi: hisi_sas: redefine hisi_sas_phy.phy_type as u32 "Martin K. Petersen" <martin.petersen@oracle.com> - 2017-06-26 19:50 +0200

csiph-web