From: Wolfgang Denk Date: Wed, 04 Feb 2009 22:38:03 +0100 Subject: [U-Boot] [PATCH 4/9] A driver for the S6E63D6 SPI display controller from Samsung In-Reply-To: References: Message-ID: <20090204213803.6C8338322908@gemini.denx.de> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Dear Guennadi Liakhovetski, In message you wrote: > This is a driver for the S6E63D6 SPI OLED display controller from Samsung. > It only provides access to controller's registers so the client can freely > configure it. > > Signed-off-by: Guennadi Liakhovetski ... > diff --git a/drivers/video/Makefile b/drivers/video/Makefile > index 7fba29f..a7dc74c 100644 > --- a/drivers/video/Makefile > +++ b/drivers/video/Makefile > @@ -34,6 +34,7 @@ COBJS-$(CONFIG_VIDEO_SED13806) += sed13806.o > COBJS-$(CONFIG_SED156X) += sed156x.o > COBJS-$(CONFIG_VIDEO_SM501) += sm501.o > COBJS-$(CONFIG_VIDEO_SMI_LYNXEM) += smiLynxEM.o > +COBJS-$(CONFIG_DISPLAY_S6E63D6) += s6e63d6.o Please keep lists sorted. And maybe we can omit the "DISPLAY_" part? > +++ b/drivers/video/s6e63d6.c ... > +/* Hardware selected value - 0 or 0x4 */ > +#define ID 0 Should this go into the board config file? > +/* Index and param differ in Register Select bit */ > +int s6e63d6_index(struct s6e63d6 *data, u8 idx) > +{ > + return send_word(data->slave, 0, idx); > +} > + > +int s6e63d6_param(struct s6e63d6 *data, u16 param) > +{ > + return send_word(data->slave, 2, param); > +} > + > +int s6e63d6_init(struct s6e63d6 *data) > +{ > + data->slave = spi_setup_slave(data->bus, data->cs, 100000, SPI_MODE_3); > + if (!data->slave) > + return 1; > + > + return 0; > +} static? or inline? Best regards, Wolfgang Denk -- DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de Substitute "damn" every time you're inclined to write "very"; your editor will delete it and the writing will be just as it should be. - Mark Twain