Displaying 13 results from an estimated 13 matches for "nvkm_probe_i2c".
2018 Aug 30
2
[PATCH v2] drm/nouveau: Fix nouveau_connector_ddc_detect()
...ret == NOUVEAU_DP_SST)
- break;
- } else
- if ((vga_switcheroo_handler_flags() &
- VGA_SWITCHEROO_CAN_SWITCH_DDC) &&
- nv_encoder->dcb->type == DCB_OUTPUT_LVDS &&
- nv_encoder->i2c) {
- int ret;
- vga_switcheroo_lock_ddc(dev->pdev);
- ret = nvkm_probe_i2c(nv_encoder->i2c, 0x50);
- vga_switcheroo_unlock_ddc(dev->pdev);
- if (ret)
+ else if (ret == NOUVEAU_DP_SST)
+ found = nv_encoder;
+
+ break;
+ case DCB_OUTPUT_LVDS:
+ switcheroo_ddc = !!(vga_switcheroo_handler_flags() &
+ VGA_SWITCHEROO_CAN_SWITCH_DDC);
+ /* fall-t...
2018 Aug 23
0
[PATCH] drm/nouveau: Fix nouveau_connector_ddc_detect()
...encoder;
+
+ break;
+ case DCB_OUTPUT_LVDS:
+ /* Can we actually probe this LVDS display? */
+ if (!((vga_switcheroo_handler_flags() &
+ VGA_SWITCHEROO_CAN_SWITCH_DDC) &&
+ nv_encoder->i2c))
+ continue;
+
vga_switcheroo_lock_ddc(dev->pdev);
- ret = nvkm_probe_i2c(nv_encoder->i2c, 0x50);
- vga_switcheroo_unlock_ddc(dev->pdev);
- if (ret)
- break;
- } else
- if (nv_encoder->i2c) {
if (nvkm_probe_i2c(nv_encoder->i2c, 0x50))
- break;
+ found = nv_encoder;
+ vga_switcheroo_unlock_ddc(dev->pdev);
+
+ break;
+ default:
+ if...
2018 Jun 30
2
[PATCH v2 5/9] drm/nouveau: Use drm_connector_for_each_possible_encoder()
...t;type == DCB_OUTPUT_LVDS &&
39c1c9011 Lukas Wunner 2016-01-11 444 nv_encoder->i2c) {
39c1c9011 Lukas Wunner 2016-01-11 445 int ret;
39c1c9011 Lukas Wunner 2016-01-11 446 vga_switcheroo_lock_ddc(dev->pdev);
39c1c9011 Lukas Wunner 2016-01-11 447 ret = nvkm_probe_i2c(nv_encoder->i2c, 0x50);
39c1c9011 Lukas Wunner 2016-01-11 448 vga_switcheroo_unlock_ddc(dev->pdev);
39c1c9011 Lukas Wunner 2016-01-11 449 if (ret)
39c1c9011 Lukas Wunner 2016-01-11 450 break;
39c1c9011 Lukas Wunner 2016-01-11 451 } else
8777c5c11 Ben Skeggs...
2016 Jan 11
0
[PATCH v5 07/12] drm/nouveau: Switch DDC when reading the EDID
...tor)
if (ret == 0)
break;
} else
+ if ((vga_switcheroo_handler_flags() &
+ VGA_SWITCHEROO_CAN_SWITCH_DDC) &&
+ nv_encoder->dcb->type == DCB_OUTPUT_LVDS &&
+ nv_encoder->i2c) {
+ int ret;
+ vga_switcheroo_lock_ddc(dev->pdev);
+ ret = nvkm_probe_i2c(nv_encoder->i2c, 0x50);
+ vga_switcheroo_unlock_ddc(dev->pdev);
+ if (ret)
+ break;
+ } else
if (nv_encoder->i2c) {
if (nvkm_probe_i2c(nv_encoder->i2c, 0x50))
break;
@@ -265,7 +277,14 @@ nouveau_connector_detect(struct drm_connector *connector, bool force)
nv_enc...
2018 Aug 30
0
[PATCH v2] drm/nouveau: Fix nouveau_connector_ddc_detect()
...- } else
> - if ((vga_switcheroo_handler_flags() &
> - VGA_SWITCHEROO_CAN_SWITCH_DDC) &&
> - nv_encoder->dcb->type == DCB_OUTPUT_LVDS &&
> - nv_encoder->i2c) {
> - int ret;
> - vga_switcheroo_lock_ddc(dev->pdev);
> - ret = nvkm_probe_i2c(nv_encoder->i2c, 0x50);
> - vga_switcheroo_unlock_ddc(dev->pdev);
> - if (ret)
> + else if (ret == NOUVEAU_DP_SST)
> + found = nv_encoder;
> +
> + break;
> + case DCB_OUTPUT_LVDS:
> + switcheroo_ddc = !!(vga_switcheroo_handler_flags() &
> +...
2018 Jul 02
0
[PATCH v2 5/9] drm/nouveau: Use drm_connector_for_each_possible_encoder()
..._LVDS &&
> 39c1c9011 Lukas Wunner 2016-01-11 444 nv_encoder->i2c) {
> 39c1c9011 Lukas Wunner 2016-01-11 445 int ret;
> 39c1c9011 Lukas Wunner 2016-01-11 446 vga_switcheroo_lock_ddc(dev->pdev);
> 39c1c9011 Lukas Wunner 2016-01-11 447 ret = nvkm_probe_i2c(nv_encoder->i2c, 0x50);
> 39c1c9011 Lukas Wunner 2016-01-11 448 vga_switcheroo_unlock_ddc(dev->pdev);
> 39c1c9011 Lukas Wunner 2016-01-11 449 if (ret)
> 39c1c9011 Lukas Wunner 2016-01-11 450 break;
> 39c1c9011 Lukas Wunner 2016-01-11 451 } else
>...
2018 Jun 28
4
[PATCH v2 0/9] drm: Third attempt at fixing the fb-helper .best_encoder() mess
From: Ville Syrjälä <ville.syrjala at linux.intel.com>
Changes from the previous version mainly involve Danoie's suggestion
of hiding the drm_encoder_find() in the iterator macro. I also polished
the msm and tilcdc cases a bit more with another small helper.
Cc: Alex Deucher <alexander.deucher at amd.com>
Cc: amd-gfx at lists.freedesktop.org
Cc: Ben Skeggs <bskeggs at
2016 Feb 20
0
[PATCH v4 3/6] iccsense: implement for ina209, ina219 and ina3221
...8 addr, u8 reg, u16 val)
+{
+ u8 buf[3] = { reg, val >> 8, val & 0xff};
+ struct i2c_msg msgs[] = {
+ { .addr = addr, .flags = 0, .len = 3, .buf = buf },
+ };
+
+ int ret = i2c_transfer(adap, msgs, ARRAY_SIZE(msgs));
+ if (ret != 1)
+ return -EIO;
+
+ return 0;
+}
+
static inline bool
nvkm_probe_i2c(struct i2c_adapter *adap, u8 addr)
{
diff --git a/drm/nouveau/include/nvkm/subdev/iccsense.h b/drm/nouveau/include/nvkm/subdev/iccsense.h
index 7fee41d..16b77a6 100644
--- a/drm/nouveau/include/nvkm/subdev/iccsense.h
+++ b/drm/nouveau/include/nvkm/subdev/iccsense.h
@@ -3,8 +3,13 @@
#include <...
2016 Jan 11
8
[PATCH v5 00/12] Enable GPU switching on pre-retina MacBook Pro
Enable GPU switching on the pre-retina MacBook Pro (2008 - 2013), v5.
The main obstacle on these machines is that the panel mode in VBIOS
is bogus. Fortunately gmux can switch DDC independently from the
display, thereby allowing the inactive GPU to probe the panel's EDID.
In short, vga_switcheroo and apple-gmux are amended with hooks to
switch DDC, DRM core is amended with a
2016 Feb 17
0
[PATCH 1/2] power sensor support
...8 addr, u8 reg, u16 val)
+{
+ u8 buf[3] = { reg, val >> 8, val & 0xff};
+ struct i2c_msg msgs[] = {
+ { .addr = addr, .flags = 0, .len = 3, .buf = buf },
+ };
+
+ int ret = i2c_transfer(adap, msgs, ARRAY_SIZE(msgs));
+ if (ret != 1)
+ return -EIO;
+
+ return 0;
+}
+
static inline bool
nvkm_probe_i2c(struct i2c_adapter *adap, u8 addr)
{
diff --git a/drm/nouveau/include/nvkm/subdev/iccsense.h b/drm/nouveau/include/nvkm/subdev/iccsense.h
new file mode 100644
index 0000000..3399c77
--- /dev/null
+++ b/drm/nouveau/include/nvkm/subdev/iccsense.h
@@ -0,0 +1,17 @@
+#ifndef __NVKM_ICCSENSE_H__
+#defin...
2016 Feb 17
3
[PATCH 0/2] Support for INA3221 power sensor
The INA3221 is usually found on mid and high end kepler+ gpus
Marins Patch implements the new iccsense subdev and all needed bits for the
INA3221 power sensor.
My Patch implements the hwmon power1 interface to expose the current power
consumption through hwmon (and can be read out via sysfs or the sensors tool)
Please test these patches for Fermi+ GPUs, that nothing gets messed up and
works as
2016 Feb 24
7
[PATCH v5 0/6] Suppor for various power sensors on GF100+
This is a complete rework from the first version I sent out.
Now the implementation is more centered around the power_rails we find in the
SENSE table instead of extdev centered. This makes the implementation a lot
easier and straightforward.
I've added support for the INA219, INA209 and INA3221 sensors found on multiple
Fermi and Kepler cards.
The power consumption is also exported via
2016 Feb 20
12
[PATCH v4 0/6] Suppor for various power sensors on GF100+
This is a complete rework from the first version I sent out.
Now the implementation is more centered around the power_rails we find in the
SENSE table instead of extdev centered. This makes the implementation a lot
easier and straightforward.
I've added support for the INA219, INA209 and INA3221 sensors found on multiple
Fermi and Kepler cards.
The power consumption is also exported via