Skip to content

Commit 4878e1e

Browse files
qzhuo2aegl
authored andcommitted
EDAC/i10nm: Explicitly set the modes of the RRL register sets
The i10nm_edac driver uses the default modes (either patrol scrub read or on-demand read) of the RRL register sets configured by the BIOS. Explicitly set the modes during the loading of the i10nm_edac driver with the module parameter retry_rd_err_log=2. Signed-off-by: Qiuxu Zhuo <qiuxu.zhuo@intel.com> Signed-off-by: Tony Luck <tony.luck@intel.com> Tested-by: Feng Xu <feng.f.xu@intel.com> Link: https://lore.kernel.org/r/20250417150724.1170168-4-qiuxu.zhuo@intel.com
1 parent eeed3e0 commit 4878e1e

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

drivers/edac/i10nm_base.c

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -73,6 +73,7 @@
7373
#define I10NM_SAD_NM_CACHEABLE(reg) GET_BITFIELD(reg, 5, 5)
7474

7575
#define RETRY_RD_ERR_LOG_UC BIT(1)
76+
#define RETRY_RD_ERR_LOG_EN_PATSPR BIT(13)
7677
#define RETRY_RD_ERR_LOG_NOOVER BIT(14)
7778
#define RETRY_RD_ERR_LOG_EN BIT(15)
7879
#define RETRY_RD_ERR_LOG_NOOVER_UC (BIT(14) | BIT(1))
@@ -114,12 +115,15 @@ static void __enable_retry_rd_err_log(struct skx_imc *imc, int chan, bool enable
114115
rrl_ctl[2] = d2;
115116

116117
s &= ~RETRY_RD_ERR_LOG_NOOVER_UC;
118+
s |= RETRY_RD_ERR_LOG_EN_PATSPR;
117119
s |= RETRY_RD_ERR_LOG_EN;
118120
d &= ~RETRY_RD_ERR_LOG_NOOVER_UC;
121+
d &= ~RETRY_RD_ERR_LOG_EN_PATSPR;
119122
d |= RETRY_RD_ERR_LOG_EN;
120123

121124
if (offsets_demand2) {
122125
d2 &= ~RETRY_RD_ERR_LOG_UC;
126+
d2 &= ~RETRY_RD_ERR_LOG_EN_PATSPR;
123127
d2 |= RETRY_RD_ERR_LOG_NOOVER;
124128
d2 |= RETRY_RD_ERR_LOG_EN;
125129
}
@@ -129,18 +133,24 @@ static void __enable_retry_rd_err_log(struct skx_imc *imc, int chan, bool enable
129133
s |= RETRY_RD_ERR_LOG_UC;
130134
if (rrl_ctl[0] & RETRY_RD_ERR_LOG_NOOVER)
131135
s |= RETRY_RD_ERR_LOG_NOOVER;
136+
if (!(rrl_ctl[0] & RETRY_RD_ERR_LOG_EN_PATSPR))
137+
s &= ~RETRY_RD_ERR_LOG_EN_PATSPR;
132138
if (!(rrl_ctl[0] & RETRY_RD_ERR_LOG_EN))
133139
s &= ~RETRY_RD_ERR_LOG_EN;
134140
if (rrl_ctl[1] & RETRY_RD_ERR_LOG_UC)
135141
d |= RETRY_RD_ERR_LOG_UC;
136142
if (rrl_ctl[1] & RETRY_RD_ERR_LOG_NOOVER)
137143
d |= RETRY_RD_ERR_LOG_NOOVER;
144+
if (rrl_ctl[1] & RETRY_RD_ERR_LOG_EN_PATSPR)
145+
d |= RETRY_RD_ERR_LOG_EN_PATSPR;
138146
if (!(rrl_ctl[1] & RETRY_RD_ERR_LOG_EN))
139147
d &= ~RETRY_RD_ERR_LOG_EN;
140148

141149
if (offsets_demand2) {
142150
if (rrl_ctl[2] & RETRY_RD_ERR_LOG_UC)
143151
d2 |= RETRY_RD_ERR_LOG_UC;
152+
if (rrl_ctl[2] & RETRY_RD_ERR_LOG_EN_PATSPR)
153+
d2 |= RETRY_RD_ERR_LOG_EN_PATSPR;
144154
if (!(rrl_ctl[2] & RETRY_RD_ERR_LOG_NOOVER))
145155
d2 &= ~RETRY_RD_ERR_LOG_NOOVER;
146156
if (!(rrl_ctl[2] & RETRY_RD_ERR_LOG_EN))

0 commit comments

Comments
 (0)