/* At the moment, since we have no VSYNC interrupt support, we simply set the palette entry directly.  */
static void s3c_fb_update_palette(struct s3c_fb *sfb, struct s3c_fb_win *win, unsigned int reg, u32 value)
/* At the moment, since we have no VSYNC interrupt support, we simply set the palette entry directly.  */
static void s3c_fb_update_palette(struct s3c_fb *sfb, struct s3c_fb_win *win, unsigned int reg, u32 value)
{
	void __iomem *palreg;
	u32 palcon;
	palreg = sfb->regs + s3c_fb_pal_reg(win->index, reg);
	dev_dbg(sfb->dev, "%s: win %d, reg %d (%p): %08x\n",
		__func__, win->index, reg, palreg, value);
	win->palette_buffer[reg] = value;
	palcon = readl(sfb->regs + WPALCON);
	writel(palcon | WPALCON_PAL_UPDATE, sfb->regs + WPALCON);
	if (s3c_fb_pal_is16(win->index))
		writew(value, palreg);
	else
		writel(value, palreg);
	writel(palcon, sfb->regs + WPALCON);
}