[xenial:linux-azure, disco:linux-azure][PATCH 0/1] [linux-azure] Request of mainline commit f73f8a504e27 in azure 16.04 and 18.04

classic Classic list List threaded Threaded
6 messages Options
Reply | Threaded
Open this post in threaded view
|

[xenial:linux-azure, disco:linux-azure][PATCH 0/1] [linux-azure] Request of mainline commit f73f8a504e27 in azure 16.04 and 18.04

Marcelo Henrique Cerri
BugLink: https://bugs.launchpad.net/bugs/1847139

As bug description.

Haiyang Zhang (1):
  PCI: hv: Use bytes 4 and 5 from instance ID as the PCI domain numbers

 drivers/pci/host/pci-hyperv.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

--
2.20.1


--
kernel-team mailing list
[hidden email]
https://lists.ubuntu.com/mailman/listinfo/kernel-team
Reply | Threaded
Open this post in threaded view
|

[xenial:linux-azure][PATCH 1/1] PCI: hv: Use bytes 4 and 5 from instance ID as the PCI domain numbers

Marcelo Henrique Cerri
From: Haiyang Zhang <[hidden email]>

BugLink: https://bugs.launchpad.net/bugs/1847139

As recommended by Azure host team, the bytes 4, 5 have more uniqueness
(info entropy) than bytes 8, 9 so use them as the PCI domain numbers.

On older hosts, bytes 4, 5 can also be used -- no backward compatibility
issues are introduced and the chance of collision is greatly reduced.

In the rare cases of collision, the driver code detects and finds
another number that is not in use.

Suggested-by: Michael Kelley <[hidden email]>
Signed-off-by: Haiyang Zhang <[hidden email]>
Signed-off-by: Lorenzo Pieralisi <[hidden email]>
Acked-by: Sasha Levin <[hidden email]>
(cherry picked from commit f73f8a504e27959576a2f4d85182202561e426f2)
[[hidden email]: adjustments due to the context difference]
Signed-off-by: Marcelo Henrique Cerri <[hidden email]>
---
 drivers/pci/host/pci-hyperv.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/pci/host/pci-hyperv.c b/drivers/pci/host/pci-hyperv.c
index 088e73642bb8..04aab2dffe2b 100644
--- a/drivers/pci/host/pci-hyperv.c
+++ b/drivers/pci/host/pci-hyperv.c
@@ -2601,8 +2601,8 @@ static int hv_pci_probe(struct hv_device *hdev,
  * between domains derived from these instance IDs in the same
  * VM.
  */
- hbus->sysdata.domain = hdev->dev_instance.b[9] |
-       hdev->dev_instance.b[8] << 8;
+ hbus->sysdata.domain = hdev->dev_instance.b[4] |
+       hdev->dev_instance.b[5] << 8;
 
  hbus->hdev = hdev;
  atomic_inc(&hbus->remove_lock);
--
2.20.1


--
kernel-team mailing list
[hidden email]
https://lists.ubuntu.com/mailman/listinfo/kernel-team
Reply | Threaded
Open this post in threaded view
|

[disco:linux-azure][PATCH] PCI: hv: Use bytes 4 and 5 from instance ID as the PCI domain numbers

Marcelo Henrique Cerri
In reply to this post by Marcelo Henrique Cerri
From: Haiyang Zhang <[hidden email]>

BugLink: https://bugs.launchpad.net/bugs/1847139

As recommended by Azure host team, the bytes 4, 5 have more uniqueness
(info entropy) than bytes 8, 9 so use them as the PCI domain numbers.

On older hosts, bytes 4, 5 can also be used -- no backward compatibility
issues are introduced and the chance of collision is greatly reduced.

In the rare cases of collision, the driver code detects and finds
another number that is not in use.

Suggested-by: Michael Kelley <[hidden email]>
Signed-off-by: Haiyang Zhang <[hidden email]>
Signed-off-by: Lorenzo Pieralisi <[hidden email]>
Acked-by: Sasha Levin <[hidden email]>
(cherry picked from commit f73f8a504e27959576a2f4d85182202561e426f2)
[[hidden email]: adjustments due to the context difference]
Signed-off-by: Marcelo Henrique Cerri <[hidden email]>
---
 drivers/pci/controller/pci-hyperv.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/pci/controller/pci-hyperv.c b/drivers/pci/controller/pci-hyperv.c
index 3bd94149b9d2..36b3c85f6574 100644
--- a/drivers/pci/controller/pci-hyperv.c
+++ b/drivers/pci/controller/pci-hyperv.c
@@ -2559,8 +2559,8 @@ static int hv_pci_probe(struct hv_device *hdev,
  * between domains derived from these instance IDs in the same
  * VM.
  */
- hbus->sysdata.domain = hdev->dev_instance.b[9] |
-       hdev->dev_instance.b[8] << 8;
+ hbus->sysdata.domain = hdev->dev_instance.b[4] |
+       hdev->dev_instance.b[5] << 8;
 
  hbus->hdev = hdev;
  refcount_set(&hbus->remove_lock, 1);
--
2.20.1


--
kernel-team mailing list
[hidden email]
https://lists.ubuntu.com/mailman/listinfo/kernel-team
Reply | Threaded
Open this post in threaded view
|

ACK: [xenial:linux-azure, disco:linux-azure][PATCH 0/1] [linux-azure] Request of mainline commit f73f8a504e27 in azure 16.04 and 18.04

Seth Forshee
In reply to this post by Marcelo Henrique Cerri
On Wed, Oct 16, 2019 at 05:28:29PM -0300, Marcelo Henrique Cerri wrote:
> BugLink: https://bugs.launchpad.net/bugs/1847139
>
> As bug description.
>
> Haiyang Zhang (1):
>   PCI: hv: Use bytes 4 and 5 from instance ID as the PCI domain numbers
>
>  drivers/pci/host/pci-hyperv.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)

Acked-by: Seth Forshee <[hidden email]>

--
kernel-team mailing list
[hidden email]
https://lists.ubuntu.com/mailman/listinfo/kernel-team
Reply | Threaded
Open this post in threaded view
|

ACK: [xenial:linux-azure, disco:linux-azure][PATCH 0/1] [linux-azure] Request of mainline commit f73f8a504e27 in azure 16.04 and 18.04

Connor Kuehl
In reply to this post by Marcelo Henrique Cerri
On 10/16/19 1:28 PM, Marcelo Henrique Cerri wrote:

> BugLink: https://bugs.launchpad.net/bugs/1847139
>
> As bug description.
>
> Haiyang Zhang (1):
>    PCI: hv: Use bytes 4 and 5 from instance ID as the PCI domain numbers
>
>   drivers/pci/host/pci-hyperv.c | 4 ++--
>   1 file changed, 2 insertions(+), 2 deletions(-)
>

Acked-by: Connor Kuehl <[hidden email]>

--
kernel-team mailing list
[hidden email]
https://lists.ubuntu.com/mailman/listinfo/kernel-team
Reply | Threaded
Open this post in threaded view
|

APPLIED: [xenial:linux-azure, disco:linux-azure][PATCH 0/1] [linux-azure] Request of mainline commit f73f8a504e27 in azure 16.04 and 18.04

Kleber Souza
In reply to this post by Marcelo Henrique Cerri
On 16.10.19 22:28, Marcelo Henrique Cerri wrote:

> BugLink: https://bugs.launchpad.net/bugs/1847139
>
> As bug description.
>
> Haiyang Zhang (1):
>   PCI: hv: Use bytes 4 and 5 from instance ID as the PCI domain numbers
>
>  drivers/pci/host/pci-hyperv.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
>

Applied to xenial/linux-azure and disco/linux-azure master-next branches.

Thanks,
Kleber

--
kernel-team mailing list
[hidden email]
https://lists.ubuntu.com/mailman/listinfo/kernel-team