Lines Matching refs:reg

782  *   - reset the chip using the reset reg
1183 #define NEEDS_FORCE_WAKE(dev_priv, reg) \
1185 ((reg) < 0x40000) && \
1186 ((reg) != FORCEWAKE))
1198 hsw_unclaimed_reg_clear(struct drm_i915_private *dev_priv, u32 reg)
1203 reg);
1209 hsw_unclaimed_reg_check(struct drm_i915_private *dev_priv, u32 reg)
1213 DRM_INFO("Unclaimed write to %x\n", reg);
1218 u8 i915_read8(struct drm_i915_private *dev_priv, u32 reg)
1225 if (NEEDS_FORCE_WAKE(dev_priv, reg)) {
1230 val = DRM_READ8(dev_priv->regs, reg);
1235 val = DRM_READ8(dev_priv->regs, (reg));
1239 u16 i915_read16(struct drm_i915_private *dev_priv, u32 reg)
1246 if (NEEDS_FORCE_WAKE(dev_priv, reg)) {
1251 val = DRM_READ16(dev_priv->regs, reg);
1256 val = DRM_READ16(dev_priv->regs, (reg));
1260 u32 i915_read32(struct drm_i915_private *dev_priv, u32 reg)
1267 if (NEEDS_FORCE_WAKE(dev_priv, reg)) {
1272 val = DRM_READ32(dev_priv->regs, reg);
1277 val = DRM_READ32(dev_priv->regs, (reg));
1281 u64 i915_read64(struct drm_i915_private *dev_priv, u32 reg)
1288 if (NEEDS_FORCE_WAKE(dev_priv, reg)) {
1293 val = DRM_READ64(dev_priv->regs, reg);
1298 val = DRM_READ64(dev_priv->regs, (reg));
1302 void i915_write8(struct drm_i915_private *dev_priv, u32 reg,
1309 if (NEEDS_FORCE_WAKE(dev_priv, reg))
1315 hsw_unclaimed_reg_clear(dev_priv, reg);
1317 DRM_WRITE8(dev_priv->regs, (reg), (val));
1320 hsw_unclaimed_reg_check(dev_priv, reg);
1324 void i915_write16(struct drm_i915_private *dev_priv, u32 reg,
1331 if (NEEDS_FORCE_WAKE(dev_priv, reg))
1337 hsw_unclaimed_reg_clear(dev_priv, reg);
1339 DRM_WRITE16(dev_priv->regs, (reg), (val));
1342 hsw_unclaimed_reg_check(dev_priv, reg);
1346 void i915_write32(struct drm_i915_private *dev_priv, u32 reg,
1353 if (NEEDS_FORCE_WAKE(dev_priv, reg))
1359 hsw_unclaimed_reg_clear(dev_priv, reg);
1361 DRM_WRITE32(dev_priv->regs, (reg), (val));
1364 hsw_unclaimed_reg_check(dev_priv, reg);
1368 void i915_write64(struct drm_i915_private *dev_priv, u32 reg,
1375 if (NEEDS_FORCE_WAKE(dev_priv, reg))
1381 hsw_unclaimed_reg_clear(dev_priv, reg);
1383 DRM_WRITE64(dev_priv->regs, (reg), (val));
1386 hsw_unclaimed_reg_check(dev_priv, reg);
1391 u ## x i915_read ## x(struct drm_i915_private *dev_priv, u32 reg);
1400 void i915_write ## x(struct drm_i915_private *dev_priv, u32 reg, \
1420 struct drm_i915_reg_read *reg = data;
1425 if (entry->offset == reg->offset &&
1435 reg->val = I915_READ64(reg->offset);
1438 reg->val = I915_READ(reg->offset);
1441 reg->val = I915_READ16(reg->offset);
1444 reg->val = I915_READ8(reg->offset);