View | Details | Raw Unified | Return to bug 13285
Collapse All | Expand All

(-)src/gfx/gfx_init.c.orig (-4 / +9 lines)
Lines 517-529 Link Here
517
unsigned long
517
unsigned long
518
gfx_pci_config_read(unsigned long address)
518
gfx_pci_config_read(unsigned long address)
519
{
519
{
520
   unsigned long value = 0xFFFFFFFF;
520
	unsigned long value = 0xFFFFFFFF;
521
	
522
	outl(address, PCI_CONFIG_ADDR);
523
	value = inl(PCI_CONFIG_DATA);
524
	/* OUTD(PCI_CONFIG_ADDR, address);
525
	value = IND(PCI_CONFIG_DATA); */
521
526
522
   OUTD(PCI_CONFIG_ADDR, address);
527
	return (value);
523
   value = IND(PCI_CONFIG_DATA);
524
   return (value);
525
}
528
}
526
529
530
531
527
/*-----------------------------------------------------------------------------
532
/*-----------------------------------------------------------------------------
528
 * gfx_pci_config_write
533
 * gfx_pci_config_write
529
 * 
534
 * 
(-)src/gfx/init_gu1.c.orig (-11 / +21 lines)
Lines 128-133 Link Here
128
 * Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 
128
 * Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 
129
 *
129
 *
130
 * END_NSC_LIC_GPL */
130
 * END_NSC_LIC_GPL */
131
#include <sys/io.h>
131
132
132
unsigned char gfx_gxm_config_read(unsigned char index);
133
unsigned char gfx_gxm_config_read(unsigned char index);
133
unsigned long gu1_get_core_freq(void);
134
unsigned long gu1_get_core_freq(void);
Lines 149-166 Link Here
149
unsigned char
150
unsigned char
150
gfx_gxm_config_read(unsigned char index)
151
gfx_gxm_config_read(unsigned char index)
151
{
152
{
152
   unsigned char value = 0xFF;
153
	unsigned char value = 0xFF;
153
   unsigned char lock;
154
	unsigned char lock;
154
155
155
   OUTB(0x22, GXM_CONFIG_CCR3);
156
/* OUTB(0x22, GXM_CONFIG_CCR3);
156
   lock = INB(0x23);
157
	lock = INB(0x23);
157
   OUTB(0x22, GXM_CONFIG_CCR3);
158
	OUTB(0x22, GXM_CONFIG_CCR3);
158
   OUTB(0x23, (unsigned char)(lock | 0x10));
159
	OUTB(0x23, (unsigned char)(lock | 0x10));
159
   OUTB(0x22, index);
160
	OUTB(0x22, index);
160
   value = INB(0x23);
161
	value = INB(0x23);
161
   OUTB(0x22, GXM_CONFIG_CCR3);
162
	OUTB(0x22, GXM_CONFIG_CCR3);
162
   OUTB(0x23, lock);
163
	OUTB(0x23, lock); */
163
   return (value);
164
165
	outb(GXM_CONFIG_CCR3,0x22);
166
	lock = inb(0x23);
167
	outb(GXM_CONFIG_CCR3,0x22);
168
	outb( (unsigned char)(lock | 0x10),0x23);
169
	outb( index,0x22);
170
	value = inb(0x23);
171
	outb(GXM_CONFIG_CCR3,0x22);
172
	outb( lock,0x23);
173
	return (value);
164
}
174
}
165
175
166
/*-----------------------------------------------------------------------------
176
/*-----------------------------------------------------------------------------

Return to bug 13285