Skip to content

Commit 6d52cb7

Browse files
rosatomjjoergroedel
authored andcommitted
s390/pci: check for relaxed translation capability
For each zdev, record whether or not CLP indicates relaxed translation capability for the associated device group. Reviewed-by: Niklas Schnelle <[email protected]> Tested-by: Niklas Schnelle <[email protected]> Signed-off-by: Matthew Rosato <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Joerg Roedel <[email protected]>
1 parent 0ad2507 commit 6d52cb7

File tree

3 files changed

+5
-2
lines changed

3 files changed

+5
-2
lines changed

arch/s390/include/asm/pci.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -144,7 +144,7 @@ struct zpci_dev {
144144
u8 util_str_avail : 1;
145145
u8 irqs_registered : 1;
146146
u8 tid_avail : 1;
147-
u8 reserved : 1;
147+
u8 rtr_avail : 1; /* Relaxed translation allowed */
148148
unsigned int devfn; /* DEVFN part of the RID*/
149149

150150
u8 pfip[CLP_PFIP_NR_SEGMENTS]; /* pci function internal path */

arch/s390/include/asm/pci_clp.h

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -156,7 +156,9 @@ struct clp_rsp_query_pci_grp {
156156
u16 : 4;
157157
u16 noi : 12; /* number of interrupts */
158158
u8 version;
159-
u8 : 6;
159+
u8 : 2;
160+
u8 rtr : 1; /* Relaxed translation requirement */
161+
u8 : 3;
160162
u8 frame : 1;
161163
u8 refresh : 1; /* TLB refresh mode */
162164
u16 : 3;

arch/s390/pci/pci_clp.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -112,6 +112,7 @@ static void clp_store_query_pci_fngrp(struct zpci_dev *zdev,
112112
zdev->version = response->version;
113113
zdev->maxstbl = response->maxstbl;
114114
zdev->dtsm = response->dtsm;
115+
zdev->rtr_avail = response->rtr;
115116

116117
switch (response->version) {
117118
case 1:

0 commit comments

Comments
 (0)