disp.h (db2bec187dd68e79d512112df1f6e7a849e7f0ce) | disp.h (967e7bde8739fe3b215f7537e8f1f39c044902af) |
---|---|
1#ifndef __NV04_DISPLAY_H__ 2#define __NV04_DISPLAY_H__ 3 4#include <subdev/bios/pll.h> 5 6#include "nouveau_display.h" 7 8enum nv04_fp_display_regs { --- 117 unchanged lines hidden (view full) --- 126void nouveau_overlay_init(struct drm_device *dev); 127 128static inline bool 129nv_two_heads(struct drm_device *dev) 130{ 131 struct nouveau_drm *drm = nouveau_drm(dev); 132 const int impl = dev->pdev->device & 0x0ff0; 133 | 1#ifndef __NV04_DISPLAY_H__ 2#define __NV04_DISPLAY_H__ 3 4#include <subdev/bios/pll.h> 5 6#include "nouveau_display.h" 7 8enum nv04_fp_display_regs { --- 117 unchanged lines hidden (view full) --- 126void nouveau_overlay_init(struct drm_device *dev); 127 128static inline bool 129nv_two_heads(struct drm_device *dev) 130{ 131 struct nouveau_drm *drm = nouveau_drm(dev); 132 const int impl = dev->pdev->device & 0x0ff0; 133 |
134 if (nv_device(drm->device)->card_type >= NV_10 && impl != 0x0100 && | 134 if (drm->device.info.family >= NV_DEVICE_INFO_V0_CELSIUS && impl != 0x0100 && |
135 impl != 0x0150 && impl != 0x01a0 && impl != 0x0200) 136 return true; 137 138 return false; 139} 140 141static inline bool 142nv_gf4_disp_arch(struct drm_device *dev) 143{ 144 return nv_two_heads(dev) && (dev->pdev->device & 0x0ff0) != 0x0110; 145} 146 147static inline bool 148nv_two_reg_pll(struct drm_device *dev) 149{ 150 struct nouveau_drm *drm = nouveau_drm(dev); 151 const int impl = dev->pdev->device & 0x0ff0; 152 | 135 impl != 0x0150 && impl != 0x01a0 && impl != 0x0200) 136 return true; 137 138 return false; 139} 140 141static inline bool 142nv_gf4_disp_arch(struct drm_device *dev) 143{ 144 return nv_two_heads(dev) && (dev->pdev->device & 0x0ff0) != 0x0110; 145} 146 147static inline bool 148nv_two_reg_pll(struct drm_device *dev) 149{ 150 struct nouveau_drm *drm = nouveau_drm(dev); 151 const int impl = dev->pdev->device & 0x0ff0; 152 |
153 if (impl == 0x0310 || impl == 0x0340 || nv_device(drm->device)->card_type >= NV_40) | 153 if (impl == 0x0310 || impl == 0x0340 || drm->device.info.family >= NV_DEVICE_INFO_V0_CURIE) |
154 return true; 155 return false; 156} 157 158static inline bool 159nv_match_device(struct drm_device *dev, unsigned device, 160 unsigned sub_vendor, unsigned sub_device) 161{ --- 5 unchanged lines hidden (view full) --- 167#include <subdev/bios.h> 168#include <subdev/bios/init.h> 169 170static inline void 171nouveau_bios_run_init_table(struct drm_device *dev, u16 table, 172 struct dcb_output *outp, int crtc) 173{ 174 struct nouveau_drm *drm = nouveau_drm(dev); | 154 return true; 155 return false; 156} 157 158static inline bool 159nv_match_device(struct drm_device *dev, unsigned device, 160 unsigned sub_vendor, unsigned sub_device) 161{ --- 5 unchanged lines hidden (view full) --- 167#include <subdev/bios.h> 168#include <subdev/bios/init.h> 169 170static inline void 171nouveau_bios_run_init_table(struct drm_device *dev, u16 table, 172 struct dcb_output *outp, int crtc) 173{ 174 struct nouveau_drm *drm = nouveau_drm(dev); |
175 struct nouveau_bios *bios = nouveau_bios(drm->device); | 175 struct nouveau_bios *bios = nvkm_bios(&drm->device); |
176 struct nvbios_init init = { 177 .subdev = nv_subdev(bios), 178 .bios = bios, 179 .offset = table, 180 .outp = outp, 181 .crtc = crtc, 182 .execute = 1, 183 }; 184 185 nvbios_exec(&init); 186} 187 188#endif | 176 struct nvbios_init init = { 177 .subdev = nv_subdev(bios), 178 .bios = bios, 179 .offset = table, 180 .outp = outp, 181 .crtc = crtc, 182 .execute = 1, 183 }; 184 185 nvbios_exec(&init); 186} 187 188#endif |