A few style fixes, no functional change
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42207 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
parent
6604b1b623
commit
ab29dee1ed
@ -73,15 +73,18 @@ DACGetElectrical(uint8 type, uint8 dac,
|
|||||||
while (list[i].pciIdMin != 0) {
|
while (list[i].pciIdMin != 0) {
|
||||||
if (list[i].pciIdMin <= info.device_id
|
if (list[i].pciIdMin <= info.device_id
|
||||||
&& list[i].pciIdMax >= info.device_id) {
|
&& list[i].pciIdMax >= info.device_id) {
|
||||||
if (*bandgap == 0) *bandgap = list[i].bandgap[dac][type];
|
if (*bandgap == 0)
|
||||||
if (*whitefine == 0) *whitefine = list[i].whitefine[dac][type];
|
*bandgap = list[i].bandgap[dac][type];
|
||||||
|
if (*whitefine == 0)
|
||||||
|
*whitefine = list[i].whitefine[dac][type];
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
i++;
|
i++;
|
||||||
}
|
}
|
||||||
if (list[i].pciIdMin != 0)
|
if (list[i].pciIdMin != 0) {
|
||||||
TRACE("%s: found new BandGap / WhiteFine in table for card!\n",
|
TRACE("%s: found new BandGap / WhiteFine in table for card!\n",
|
||||||
__func__);
|
__func__);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -99,8 +102,10 @@ DACSet(uint8 dacIndex, uint32 crtid)
|
|||||||
DACGetElectrical(standard, dacIndex, &bandGap, &whiteFine);
|
DACGetElectrical(standard, dacIndex, &bandGap, &whiteFine);
|
||||||
|
|
||||||
uint32 mask = 0;
|
uint32 mask = 0;
|
||||||
if (bandGap) mask |= 0xFF << 16;
|
if (bandGap)
|
||||||
if (whiteFine) mask |= 0xFF << 8;
|
mask |= 0xFF << 16;
|
||||||
|
if (whiteFine)
|
||||||
|
mask |= 0xFF << 8;
|
||||||
|
|
||||||
uint32 dacOffset = (dacIndex == 1) ? REG_DACB_OFFSET : REG_DACA_OFFSET;
|
uint32 dacOffset = (dacIndex == 1) ? REG_DACB_OFFSET : REG_DACA_OFFSET;
|
||||||
|
|
||||||
|
@ -5,10 +5,10 @@
|
|||||||
* Authors:
|
* Authors:
|
||||||
* Alexander von Gluck, kallisti5@unixzen.com
|
* Alexander von Gluck, kallisti5@unixzen.com
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#ifndef RADEON_HD_DAC_H
|
#ifndef RADEON_HD_DAC_H
|
||||||
#define RADEON_HD_DAC_H
|
#define RADEON_HD_DAC_H
|
||||||
|
|
||||||
|
|
||||||
// DAC Offsets
|
// DAC Offsets
|
||||||
#define REG_DACA_OFFSET 0
|
#define REG_DACA_OFFSET 0
|
||||||
#define REG_DACB_OFFSET 0x200
|
#define REG_DACB_OFFSET 0x200
|
||||||
|
@ -55,9 +55,10 @@ PLLControlTable(struct PLL_Control *table, uint16 feedbackDivider)
|
|||||||
{
|
{
|
||||||
int i;
|
int i;
|
||||||
|
|
||||||
for (i = 0; table[i].feedbackDivider < 0xFFFF ; i++)
|
for (i = 0; table[i].feedbackDivider < 0xFFFF ; i++) {
|
||||||
if (table[i].feedbackDivider >= feedbackDivider)
|
if (table[i].feedbackDivider >= feedbackDivider)
|
||||||
break;
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
return table[i].control;
|
return table[i].control;
|
||||||
}
|
}
|
||||||
@ -445,9 +446,10 @@ PLLCalibrate(uint8 pllIndex)
|
|||||||
|
|
||||||
int i;
|
int i;
|
||||||
|
|
||||||
for (i = 0; i < PLL_CALIBRATE_WAIT; i++)
|
for (i = 0; i < PLL_CALIBRATE_WAIT; i++) {
|
||||||
if (((Read32(PLL, pllControlReg) >> 20) & 0x03) == 0x03)
|
if (((Read32(PLL, pllControlReg) >> 20) & 0x03) == 0x03)
|
||||||
break;
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
if (i >= PLL_CALIBRATE_WAIT) {
|
if (i >= PLL_CALIBRATE_WAIT) {
|
||||||
if (Read32(PLL, pllControlReg) & 0x00100000) /* Calibration done? */
|
if (Read32(PLL, pllControlReg) & 0x00100000) /* Calibration done? */
|
||||||
|
Loading…
Reference in New Issue
Block a user