Displaying 2 results from an estimated 2 matches for "dcb_max_num_entri".
Did you mean:
dcb_max_num_entries
2013 Mar 13
1
Fix unaligned accesses for SPARC
...it a/drivers/gpu/drm/nouveau/nouveau_bios.h
b/drivers/gpu/drm/nouveau/nouveau_bios.h
index 7ccd28f..92031f6 100644
--- a/drivers/gpu/drm/nouveau/nouveau_bios.h
+++ b/drivers/gpu/drm/nouveau/nouveau_bios.h
@@ -26,6 +26,8 @@
#include "nvreg.h"
+#include <asm/unaligned.h>
+
#define DCB_MAX_NUM_ENTRIES 16
#define DCB_MAX_NUM_I2C_ENTRIES 16
#define DCB_MAX_NUM_GPIO_ENTRIES 32
@@ -33,10 +35,10 @@
#define DCB_LOC_ON_CHIP 0
-#define ROM16(x) le16_to_cpu(*(u16 *)&(x))
-#define ROM32(x) le32_to_cpu(*(u32 *)&(x))
+#define ROM16(x) le16_to_cpu(get_unaligned((u16 *)&(x)))
+#define ROM32...
2009 Nov 19
2
[RFC] nouveau: Add basic i2c sensor chip support
...dcb_table(struct drm_device *dev, struct nvbios *bios, bool two
{
struct bios_parsed_dcb *bdcb = &bios->bdcb;
struct parsed_dcb *dcb;
+ struct drm_nouveau_private *dev_priv = dev->dev_private;
uint16_t dcbptr, i2ctabptr = 0;
uint8_t *dcbtable;
uint8_t headerlen = 0x4, entries = DCB_MAX_NUM_ENTRIES;
@@ -5357,8 +5408,19 @@ static int parse_dcb_table(struct drm_device *dev, struct nvbios *bios, bool two
NV_WARN(dev, "No pointer to DCB I2C port table\n");
else {
bdcb->i2c_table = &bios->data[i2ctabptr];
- if (bdcb->version >= 0x30)
+ if (bdcb->version >...