> Li Frank-B20596 wrote: > > > + > > > + /* if it was disabled, re-enable the mode again */ > > > + reg = readl(host->base + CTRL); > > > + reg |= CTRL_DOTCLK_MODE; > > > + writel(reg, host->base + CTRL); > > > > writel(CTRL_DOTCLK_MODE, host->base + CTRL_SET) > > CTRL_SET is CTRL+0x4 > > SET and CLR register is easier than Read and write back. > > But you must always check, if the register really has such a SET and > CLEAR > feature. Not all registers have this feature... That's a reason why I suggest use register header that generate from xml. HW_XX_CTRL_SET will exist if there are such register in hardware. If hardware have not such register, there are not _SET and _CLR. Compiler will report error if user use _SET but hardware not such register. > > But in this case you are right. > > But I would prefer: > #define SET 4 > #define CLEAR 8 > [...] > writel(CTRL_DOTCLK_MODE, host->base + CTRL + SET) > :-) > > Regards, > Juergen -- To unsubscribe from this list: send the line "unsubscribe linux-fbdev" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html