forked from Minki/linux
drivers/video: fsl-diu-fb: clean up whitespace and formatting
Fix various indentation and line length problems in the Freescale DIU framebuffer driver. Signed-off-by: Timur Tabi <timur@freescale.com> Signed-off-by: Florian Tobias Schandinat <FlorianSchandinat@gmx.de>
This commit is contained in:
parent
be444890c8
commit
4a85dc8b7d
@ -887,7 +887,7 @@ static int fsl_diu_set_par(struct fb_info *info)
|
||||
|
||||
static inline __u32 CNVT_TOHW(__u32 val, __u32 width)
|
||||
{
|
||||
return ((val<<width) + 0x7FFF - val)>>16;
|
||||
return ((val << width) + 0x7FFF - val) >> 16;
|
||||
}
|
||||
|
||||
/*
|
||||
@ -899,8 +899,9 @@ static inline __u32 CNVT_TOHW(__u32 val, __u32 width)
|
||||
* pseudo_palette in struct fb_info. For pseudocolor mode we have a limited
|
||||
* color palette.
|
||||
*/
|
||||
static int fsl_diu_setcolreg(unsigned regno, unsigned red, unsigned green,
|
||||
unsigned blue, unsigned transp, struct fb_info *info)
|
||||
static int fsl_diu_setcolreg(unsigned int regno, unsigned int red,
|
||||
unsigned int green, unsigned int blue,
|
||||
unsigned int transp, struct fb_info *info)
|
||||
{
|
||||
int ret = 1;
|
||||
|
||||
@ -1350,6 +1351,7 @@ static irqreturn_t fsl_diu_isr(int irq, void *dev_id)
|
||||
#if defined(CONFIG_NOT_COHERENT_CACHE)
|
||||
else if (status & INT_VSYNC) {
|
||||
unsigned int i;
|
||||
|
||||
for (i = 0; i < coherence_data_size;
|
||||
i += d_cache_line_size)
|
||||
__asm__ __volatile__ (
|
||||
@ -1381,6 +1383,7 @@ static int request_irq_local(int irq)
|
||||
#if !defined(CONFIG_NOT_COHERENT_CACHE)
|
||||
ints |= INT_VSYNC;
|
||||
#endif
|
||||
|
||||
if (dr.mode == MFB_MODE2 || dr.mode == MFB_MODE3)
|
||||
ints |= INT_VSYNC_WB;
|
||||
|
||||
@ -1388,6 +1391,7 @@ static int request_irq_local(int irq)
|
||||
status = in_be32(&hw->int_status);
|
||||
out_be32(&hw->int_mask, ints);
|
||||
}
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
||||
@ -1454,15 +1458,15 @@ static int allocate_buf(struct device *dev, struct diu_addr *buf, u32 size,
|
||||
buf->paddr = (u32)buf->paddr + offset;
|
||||
} else
|
||||
buf->offset = 0;
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
static void free_buf(struct device *dev, struct diu_addr *buf, u32 size,
|
||||
u32 bytes_align)
|
||||
{
|
||||
dma_free_coherent(dev, size + bytes_align,
|
||||
buf->vaddr, (buf->paddr - buf->offset));
|
||||
return;
|
||||
dma_free_coherent(dev, size + bytes_align, buf->vaddr,
|
||||
buf->paddr - buf->offset);
|
||||
}
|
||||
|
||||
static ssize_t store_monitor(struct device *device,
|
||||
@ -1798,8 +1802,9 @@ static int __init fsl_diu_init(void)
|
||||
return -ENODEV;
|
||||
}
|
||||
|
||||
/* Freescale PLRU requires 13/8 times the cache size to do a proper
|
||||
displacement flush
|
||||
/*
|
||||
* Freescale PLRU requires 13/8 times the cache size to do a proper
|
||||
* displacement flush
|
||||
*/
|
||||
coherence_data_size = *prop * 13;
|
||||
coherence_data_size /= 8;
|
||||
@ -1816,6 +1821,7 @@ static int __init fsl_diu_init(void)
|
||||
if (!coherence_data)
|
||||
return -ENOMEM;
|
||||
#endif
|
||||
|
||||
ret = platform_driver_register(&fsl_diu_driver);
|
||||
if (ret) {
|
||||
printk(KERN_ERR
|
||||
|
Loading…
Reference in New Issue
Block a user