NV_WRITE(NV50_PDISPLAY_UNK_388, 0x150000);
NV_WRITE(NV50_PDISPLAY_UNK_38C, 0);
- display->preinit_done = TRUE;
+ display->preinit_done = true;
return 0;
}
/* enable clock change interrupts. */
NV_WRITE(NV50_PDISPLAY_SUPERVISOR_INTR, NV_READ(NV50_PDISPLAY_SUPERVISOR_INTR) | 0x70);
- display->init_done = TRUE;
+ display->init_done = true;
return 0;
}
NV50_DEBUG("\n");
list_for_each_entry(crtc, &display->crtcs, item) {
- crtc->blank(crtc, TRUE);
+ crtc->blank(crtc, true);
}
display->update(display);
for (i = 2200; i > 0; i -= 2) {
nv50_i2c_get_bits(chan, &clock, &data);
if (clock)
- return TRUE;
+ return true;
udelay(2);
}
printk("a timeout occured in nv50_i2c_raise_clock\n");
- return FALSE;
+ return false;
}
static bool nv50_i2c_start(struct nv50_i2c_channel *chan)
{
if (!nv50_i2c_raise_clock(chan, 1))
- return FALSE;
+ return false;
nv50_i2c_set_bits(chan, 1, 0);
udelay(5);
nv50_i2c_set_bits(chan, 0, 0);
udelay(5);
- return TRUE;
+ return true;
}
static void nv50_i2c_stop(struct nv50_i2c_channel *chan)
for (i = 7; i >= 0; i--)
if (!nv50_i2c_write_bit(chan, (byte >> i) & 1))
- return FALSE;
+ return false;
nv50_i2c_set_bits(chan, 0, 1);
udelay(5);
if (i <= 0) {
printk("a timeout occured in nv50_i2c_write_byte\n");
- rval = FALSE;
+ rval = false;
}
}
if (bit)
*byte |= (1 << i);
} else {
- return FALSE;
+ return false;
}
}
if (!nv50_i2c_write_bit(chan, last ? 1 : 0))
- return FALSE;
+ return false;
- return TRUE;
+ return true;
}
/* only 7 bits addresses. */
real_addr |= 1;
if (nv50_i2c_write_byte(chan, real_addr))
- return TRUE;
+ return true;
/* failure, so issue stop */
nv50_i2c_stop(chan);
}
- return FALSE;
+ return false;
}
static bool nv50_i2c_read(struct nv50_i2c_channel *chan, uint8_t address, uint8_t *buffer, uint32_t length)
/* retries */
for (i = 0; i < 4; i++) {
- rval = nv50_i2c_address(chan, address, FALSE);
+ rval = nv50_i2c_address(chan, address, false);
if (!rval)
- return FALSE;
+ return false;
for (j = 0; j < length; j++) {
last = false;
/* retries */
for (i = 0; i < 4; i++) {
- rval = nv50_i2c_address(chan, address, TRUE);
+ rval = nv50_i2c_address(chan, address, true);
if (!rval)
- return FALSE;
+ return false;
for (j = 0; j < length; j++) {
rval = nv50_i2c_write_byte(chan, buffer[j]);
if (blank) {
crtc = to_nv50_crtc(set->crtc);
- rval = crtc->blank(crtc, TRUE);
+ rval = crtc->blank(crtc, true);
if (rval != 0) {
DRM_ERROR("blanking failed\n");
goto out;
if (drm_encoder->crtc == set->crtc) {
output = to_nv50_output(drm_encoder);
- rval = output->execute_mode(output, TRUE);
+ rval = output->execute_mode(output, true);
if (rval != 0) {
DRM_ERROR("detaching output failed\n");
goto out;
if (switch_fb && !modeset && !blank) {
crtc = to_nv50_crtc(set->crtc);
- rval = crtc->blank(crtc, TRUE);
+ rval = crtc->blank(crtc, true);
if (rval != 0) {
DRM_ERROR("blanking failed\n");
goto out;
}
/* this also sets the fb offset */
- rval = crtc->blank(crtc, FALSE);
+ rval = crtc->blank(crtc, false);
if (rval != 0) {
DRM_ERROR("unblanking failed\n");
goto out;
if (output->crtc) {
crtc_mask |= 1 << output->crtc->index;
} else {
- rval = output->execute_mode(output, TRUE);
+ rval = output->execute_mode(output, true);
if (rval != 0) {
DRM_ERROR("detaching output failed\n");
goto out;
/* blank any unused crtcs */
list_for_each_entry(crtc, &display->crtcs, item) {
if (!(crtc_mask & (1 << crtc->index)))
- crtc->blank(crtc, TRUE);
+ crtc->blank(crtc, true);
}
crtc = to_nv50_crtc(set->crtc);
if (output->crtc != crtc)
continue;
- rval = output->execute_mode(output, FALSE);
+ rval = output->execute_mode(output, false);
if (rval != 0) {
DRM_ERROR("output execute mode failed\n");
goto out;
}
}
- drm_mode_prune_invalid(drm_connector->dev, &drm_connector->modes, TRUE);
+ drm_mode_prune_invalid(drm_connector->dev, &drm_connector->modes, true);
if (list_empty(&drm_connector->modes)) {
struct drm_display_mode *stdmode;
crtc->fb->block = NULL;
if (!crtc->blanked)
- crtc->blank(crtc, TRUE);
+ crtc->blank(crtc, true);
}
if (crtc->cursor->block == block) {