All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 1/2] arm: msm: video: add msm_fb.h
@ 2010-04-23 23:20 Daniel Walker
  2010-04-23 23:20 ` [PATCH 2/2] drivers: video: msm: add include msm_mdp.h Daniel Walker
  2010-04-24  5:24 ` [PATCH 1/2] arm: msm: video: add msm_fb.h Pavel Machek
  0 siblings, 2 replies; 7+ messages in thread
From: Daniel Walker @ 2010-04-23 23:20 UTC (permalink / raw)
  To: linux-arm-msm; +Cc: Daniel Walker

Also drops the old mddi structure, which conflicts with the new
file.

Signed-off-by: Daniel Walker <dwalker@codeaurora.org>
---
 arch/arm/mach-msm/include/mach/board.h  |    8 --
 arch/arm/mach-msm/include/mach/msm_fb.h |  147 +++++++++++++++++++++++++++++++
 2 files changed, 147 insertions(+), 8 deletions(-)
 create mode 100644 arch/arm/mach-msm/include/mach/msm_fb.h

diff --git a/arch/arm/mach-msm/include/mach/board.h b/arch/arm/mach-msm/include/mach/board.h
index 264d62e..864388d 100644
--- a/arch/arm/mach-msm/include/mach/board.h
+++ b/arch/arm/mach-msm/include/mach/board.h
@@ -19,14 +19,6 @@
 
 #include <linux/types.h>
 
-/* platform device data structures */
-
-struct msm_mddi_platform_data
-{
-	void (*panel_power)(int on);
-	unsigned has_vsync_irq:1;
-};
-
 /* common init routines for use by arch/arm/mach-msm/board-*.c */
 
 void __init msm_add_devices(void);
diff --git a/arch/arm/mach-msm/include/mach/msm_fb.h b/arch/arm/mach-msm/include/mach/msm_fb.h
new file mode 100644
index 0000000..1f4fc81
--- /dev/null
+++ b/arch/arm/mach-msm/include/mach/msm_fb.h
@@ -0,0 +1,147 @@
+/* arch/arm/mach-msm/include/mach/msm_fb.h
+ *
+ * Internal shared definitions for various MSM framebuffer parts.
+ *
+ * Copyright (C) 2007 Google Incorporated
+ *
+ * This software is licensed under the terms of the GNU General Public
+ * License version 2, as published by the Free Software Foundation, and
+ * may be copied, distributed, and modified under those terms.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ */
+
+#ifndef _MSM_FB_H_
+#define _MSM_FB_H_
+
+#include <linux/device.h>
+
+struct mddi_info;
+
+struct msm_fb_data {
+	int xres;	/* x resolution in pixels */
+	int yres;	/* y resolution in pixels */
+	int width;	/* disply width in mm */
+	int height;	/* display height in mm */
+	unsigned output_format;
+};
+
+struct msmfb_callback {
+	void (*func)(struct msmfb_callback *);
+};
+
+enum {
+	MSM_MDDI_PMDH_INTERFACE,
+	MSM_MDDI_EMDH_INTERFACE,
+	MSM_EBI2_INTERFACE,
+};
+
+#define MSMFB_CAP_PARTIAL_UPDATES	(1 << 0)
+
+struct msm_panel_data {
+	/* turns off the fb memory */
+	int (*suspend)(struct msm_panel_data *);
+	/* turns on the fb memory */
+	int (*resume)(struct msm_panel_data *);
+	/* turns off the panel */
+	int (*blank)(struct msm_panel_data *);
+	/* turns on the panel */
+	int (*unblank)(struct msm_panel_data *);
+	void (*wait_vsync)(struct msm_panel_data *);
+	void (*request_vsync)(struct msm_panel_data *, struct msmfb_callback *);
+	void (*clear_vsync)(struct msm_panel_data *);
+	/* from the enum above */
+	unsigned interface_type;
+	/* data to be passed to the fb driver */
+	struct msm_fb_data *fb_data;
+
+	/* capabilities supported by the panel */
+	uint32_t caps;
+};
+
+struct msm_mddi_client_data {
+	void (*suspend)(struct msm_mddi_client_data *);
+	void (*resume)(struct msm_mddi_client_data *);
+	void (*activate_link)(struct msm_mddi_client_data *);
+	void (*remote_write)(struct msm_mddi_client_data *, uint32_t val,
+			     uint32_t reg);
+	uint32_t (*remote_read)(struct msm_mddi_client_data *, uint32_t reg);
+	void (*auto_hibernate)(struct msm_mddi_client_data *, int);
+	/* custom data that needs to be passed from the board file to a 
+	 * particular client */
+	void *private_client_data;
+	struct resource *fb_resource;
+	/* from the list above */
+	unsigned interface_type;
+};
+
+struct msm_mddi_platform_data {
+	unsigned int clk_rate;
+	void (*power_client)(struct msm_mddi_client_data *, int on);
+
+	/* fixup the mfr name, product id */
+	void (*fixup)(uint16_t *mfr_name, uint16_t *product_id);
+
+	struct resource *fb_resource; /*optional*/
+	/* number of clients in the list that follows */
+	int num_clients;
+	/* array of client information of clients */
+	struct {
+		unsigned product_id; /* mfr id in top 16 bits, product id
+				      * in lower 16 bits
+				      */
+		char *name;	/* the device name will be the platform
+				 * device name registered for the client,
+				 * it should match the name of the associated
+				 * driver
+				 */
+		unsigned id;	/* id for mddi client device node, will also
+				 * be used as device id of panel devices, if
+				 * the client device will have multiple panels
+				 * space must be left here for them
+				 */
+		void *client_data;	/* required private client data */
+		unsigned int clk_rate;	/* optional: if the client requires a
+					* different mddi clk rate
+					*/
+	} client_platform_data[];
+};
+
+struct mdp_blit_req;
+struct fb_info;
+struct mdp_device {
+	struct device dev;
+	void (*dma)(struct mdp_device *mpd, uint32_t addr,
+		    uint32_t stride, uint32_t w, uint32_t h, uint32_t x,
+		    uint32_t y, struct msmfb_callback *callback, int interface);
+	void (*dma_wait)(struct mdp_device *mdp);
+	int (*blit)(struct mdp_device *mdp, struct fb_info *fb,
+		    struct mdp_blit_req *req);
+	void (*set_grp_disp)(struct mdp_device *mdp, uint32_t disp_id);
+};
+
+struct class_interface;
+int register_mdp_client(struct class_interface *class_intf);
+
+/**** private client data structs go below this line ***/
+
+struct msm_mddi_bridge_platform_data {
+	/* from board file */
+	int (*init)(struct msm_mddi_bridge_platform_data *,
+		    struct msm_mddi_client_data *);
+	int (*uninit)(struct msm_mddi_bridge_platform_data *,
+		      struct msm_mddi_client_data *);
+	/* passed to panel for use by the fb driver */
+	int (*blank)(struct msm_mddi_bridge_platform_data *,
+		     struct msm_mddi_client_data *);
+	int (*unblank)(struct msm_mddi_bridge_platform_data *,
+		       struct msm_mddi_client_data *);
+	struct msm_fb_data fb_data;
+};
+
+
+
+#endif
-- 
1.6.2.3


^ permalink raw reply related	[flat|nested] 7+ messages in thread

* [PATCH 2/2] drivers: video: msm: add include msm_mdp.h
  2010-04-23 23:20 [PATCH 1/2] arm: msm: video: add msm_fb.h Daniel Walker
@ 2010-04-23 23:20 ` Daniel Walker
  2010-04-23 23:32   ` Daniel Walker
  2010-04-24  5:25   ` Pavel Machek
  2010-04-24  5:24 ` [PATCH 1/2] arm: msm: video: add msm_fb.h Pavel Machek
  1 sibling, 2 replies; 7+ messages in thread
From: Daniel Walker @ 2010-04-23 23:20 UTC (permalink / raw)
  To: linux-arm-msm; +Cc: Daniel Walker

Needed to get the driver to compile ;(

Signed-off-by: Daniel Walker <dwalker@codeaurora.org>
---
 include/linux/msm_mdp.h |   86 +++++++++++++++++++++++++++++++++++++++++++++++
 1 files changed, 86 insertions(+), 0 deletions(-)
 create mode 100644 include/linux/msm_mdp.h

diff --git a/include/linux/msm_mdp.h b/include/linux/msm_mdp.h
new file mode 100644
index 0000000..9065dc6
--- /dev/null
+++ b/include/linux/msm_mdp.h
@@ -0,0 +1,86 @@
+/* include/linux/msm_mdp.h
+ *
+ * Copyright (C) 2007 Google Incorporated
+ *
+ * This software is licensed under the terms of the GNU General Public
+ * License version 2, as published by the Free Software Foundation, and
+ * may be copied, distributed, and modified under those terms.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ */
+#ifndef _MSM_MDP_H_
+#define _MSM_MDP_H_
+
+#include <linux/types.h>
+
+#define MSMFB_IOCTL_MAGIC 'm'
+#define MSMFB_GRP_DISP          _IOW(MSMFB_IOCTL_MAGIC, 1, unsigned int)
+#define MSMFB_BLIT              _IOW(MSMFB_IOCTL_MAGIC, 2, unsigned int)
+
+enum {
+	MDP_RGB_565,      // RGB 565 planer
+	MDP_XRGB_8888,    // RGB 888 padded
+	MDP_Y_CBCR_H2V2,  // Y and CbCr, pseudo planer w/ Cb is in MSB
+	MDP_ARGB_8888,    // ARGB 888
+	MDP_RGB_888,      // RGB 888 planer
+	MDP_Y_CRCB_H2V2,  // Y and CrCb, pseudo planer w/ Cr is in MSB
+	MDP_YCRYCB_H2V1,  // YCrYCb interleave
+	MDP_Y_CRCB_H2V1,  // Y and CrCb, pseduo planer w/ Cr is in MSB
+	MDP_Y_CBCR_H2V1,   // Y and CrCb, pseduo planer w/ Cr is in MSB
+	MDP_RGBA_8888,    // ARGB 888
+	MDP_BGRA_8888,    // ARGB 888
+	MDP_IMGTYPE_LIMIT // Non valid image type after this enum
+};
+
+enum {
+	PMEM_IMG,
+	FB_IMG,
+};
+
+/* flag values */
+#define MDP_ROT_NOP 0
+#define MDP_FLIP_LR 0x1
+#define MDP_FLIP_UD 0x2
+#define MDP_ROT_90 0x4
+#define MDP_ROT_180 (MDP_FLIP_UD|MDP_FLIP_LR)
+#define MDP_ROT_270 (MDP_ROT_90|MDP_FLIP_UD|MDP_FLIP_LR)
+#define MDP_DITHER 0x8
+#define MDP_BLUR 0x10
+
+#define MDP_TRANSP_NOP 0xffffffff
+#define MDP_ALPHA_NOP 0xff
+
+struct mdp_rect {
+	uint32_t x;
+	uint32_t y;
+	uint32_t w;
+	uint32_t h;
+};
+
+struct mdp_img {
+	uint32_t width;
+	uint32_t height;
+	uint32_t format;
+	uint32_t offset;
+	int memory_id;		/* the file descriptor */
+};
+
+struct mdp_blit_req {
+	struct mdp_img src;
+	struct mdp_img dst;
+	struct mdp_rect src_rect;
+	struct mdp_rect dst_rect;
+	uint32_t alpha;
+	uint32_t transp_mask;
+	uint32_t flags;
+};
+
+struct mdp_blit_req_list {
+	uint32_t count;
+	struct mdp_blit_req req[];
+};
+
+#endif //_MSM_MDP_H_
-- 
1.6.2.3


^ permalink raw reply related	[flat|nested] 7+ messages in thread

* Re: [PATCH 2/2] drivers: video: msm: add include msm_mdp.h
  2010-04-23 23:20 ` [PATCH 2/2] drivers: video: msm: add include msm_mdp.h Daniel Walker
@ 2010-04-23 23:32   ` Daniel Walker
  2010-04-24  5:25   ` Pavel Machek
  1 sibling, 0 replies; 7+ messages in thread
From: Daniel Walker @ 2010-04-23 23:32 UTC (permalink / raw)
  To: linux-arm-msm

On Fri, 2010-04-23 at 16:20 -0700, Daniel Walker wrote:
> Needed to get the driver to compile ;(

I have no idea yet if the framebuffer works, but I got it to compile
with these changes..

Daniel



^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [PATCH 1/2] arm: msm: video: add msm_fb.h
  2010-04-23 23:20 [PATCH 1/2] arm: msm: video: add msm_fb.h Daniel Walker
  2010-04-23 23:20 ` [PATCH 2/2] drivers: video: msm: add include msm_mdp.h Daniel Walker
@ 2010-04-24  5:24 ` Pavel Machek
  1 sibling, 0 replies; 7+ messages in thread
From: Pavel Machek @ 2010-04-24  5:24 UTC (permalink / raw)
  To: Daniel Walker; +Cc: linux-arm-msm

On Fri 2010-04-23 16:20:20, Daniel Walker wrote:
> Also drops the old mddi structure, which conflicts with the new
> file.
> 
> Signed-off-by: Daniel Walker <dwalker@codeaurora.org>

ACK.

> ---
>  arch/arm/mach-msm/include/mach/board.h  |    8 --
>  arch/arm/mach-msm/include/mach/msm_fb.h |  147 +++++++++++++++++++++++++++++++
>  2 files changed, 147 insertions(+), 8 deletions(-)
>  create mode 100644 arch/arm/mach-msm/include/mach/msm_fb.h
> 
> diff --git a/arch/arm/mach-msm/include/mach/board.h b/arch/arm/mach-msm/include/mach/board.h
> index 264d62e..864388d 100644
> --- a/arch/arm/mach-msm/include/mach/board.h
> +++ b/arch/arm/mach-msm/include/mach/board.h
> @@ -19,14 +19,6 @@
>  
>  #include <linux/types.h>
>  
> -/* platform device data structures */
> -
> -struct msm_mddi_platform_data
> -{
> -	void (*panel_power)(int on);
> -	unsigned has_vsync_irq:1;
> -};
> -
>  /* common init routines for use by arch/arm/mach-msm/board-*.c */
>  
>  void __init msm_add_devices(void);
> diff --git a/arch/arm/mach-msm/include/mach/msm_fb.h b/arch/arm/mach-msm/include/mach/msm_fb.h
> new file mode 100644
> index 0000000..1f4fc81
> --- /dev/null
> +++ b/arch/arm/mach-msm/include/mach/msm_fb.h
> @@ -0,0 +1,147 @@
> +/* arch/arm/mach-msm/include/mach/msm_fb.h
> + *
> + * Internal shared definitions for various MSM framebuffer parts.
> + *
> + * Copyright (C) 2007 Google Incorporated
> + *
> + * This software is licensed under the terms of the GNU General Public
> + * License version 2, as published by the Free Software Foundation, and
> + * may be copied, distributed, and modified under those terms.
> + *
> + * This program is distributed in the hope that it will be useful,
> + * but WITHOUT ANY WARRANTY; without even the implied warranty of
> + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
> + * GNU General Public License for more details.
> + */
> +
> +#ifndef _MSM_FB_H_
> +#define _MSM_FB_H_
> +
> +#include <linux/device.h>
> +
> +struct mddi_info;
> +
> +struct msm_fb_data {
> +	int xres;	/* x resolution in pixels */
> +	int yres;	/* y resolution in pixels */
> +	int width;	/* disply width in mm */
> +	int height;	/* display height in mm */
> +	unsigned output_format;
> +};
> +
> +struct msmfb_callback {
> +	void (*func)(struct msmfb_callback *);
> +};
> +
> +enum {
> +	MSM_MDDI_PMDH_INTERFACE,
> +	MSM_MDDI_EMDH_INTERFACE,
> +	MSM_EBI2_INTERFACE,
> +};
> +
> +#define MSMFB_CAP_PARTIAL_UPDATES	(1 << 0)
> +
> +struct msm_panel_data {
> +	/* turns off the fb memory */
> +	int (*suspend)(struct msm_panel_data *);
> +	/* turns on the fb memory */
> +	int (*resume)(struct msm_panel_data *);
> +	/* turns off the panel */
> +	int (*blank)(struct msm_panel_data *);
> +	/* turns on the panel */
> +	int (*unblank)(struct msm_panel_data *);
> +	void (*wait_vsync)(struct msm_panel_data *);
> +	void (*request_vsync)(struct msm_panel_data *, struct msmfb_callback *);
> +	void (*clear_vsync)(struct msm_panel_data *);
> +	/* from the enum above */
> +	unsigned interface_type;
> +	/* data to be passed to the fb driver */
> +	struct msm_fb_data *fb_data;
> +
> +	/* capabilities supported by the panel */
> +	uint32_t caps;
> +};
> +
> +struct msm_mddi_client_data {
> +	void (*suspend)(struct msm_mddi_client_data *);
> +	void (*resume)(struct msm_mddi_client_data *);
> +	void (*activate_link)(struct msm_mddi_client_data *);
> +	void (*remote_write)(struct msm_mddi_client_data *, uint32_t val,
> +			     uint32_t reg);
> +	uint32_t (*remote_read)(struct msm_mddi_client_data *, uint32_t reg);
> +	void (*auto_hibernate)(struct msm_mddi_client_data *, int);
> +	/* custom data that needs to be passed from the board file to a 
> +	 * particular client */
> +	void *private_client_data;
> +	struct resource *fb_resource;
> +	/* from the list above */
> +	unsigned interface_type;
> +};
> +
> +struct msm_mddi_platform_data {
> +	unsigned int clk_rate;
> +	void (*power_client)(struct msm_mddi_client_data *, int on);
> +
> +	/* fixup the mfr name, product id */
> +	void (*fixup)(uint16_t *mfr_name, uint16_t *product_id);
> +
> +	struct resource *fb_resource; /*optional*/
> +	/* number of clients in the list that follows */
> +	int num_clients;
> +	/* array of client information of clients */
> +	struct {
> +		unsigned product_id; /* mfr id in top 16 bits, product id
> +				      * in lower 16 bits
> +				      */
> +		char *name;	/* the device name will be the platform
> +				 * device name registered for the client,
> +				 * it should match the name of the associated
> +				 * driver
> +				 */
> +		unsigned id;	/* id for mddi client device node, will also
> +				 * be used as device id of panel devices, if
> +				 * the client device will have multiple panels
> +				 * space must be left here for them
> +				 */
> +		void *client_data;	/* required private client data */
> +		unsigned int clk_rate;	/* optional: if the client requires a
> +					* different mddi clk rate
> +					*/
> +	} client_platform_data[];
> +};
> +
> +struct mdp_blit_req;
> +struct fb_info;
> +struct mdp_device {
> +	struct device dev;
> +	void (*dma)(struct mdp_device *mpd, uint32_t addr,
> +		    uint32_t stride, uint32_t w, uint32_t h, uint32_t x,
> +		    uint32_t y, struct msmfb_callback *callback, int interface);
> +	void (*dma_wait)(struct mdp_device *mdp);
> +	int (*blit)(struct mdp_device *mdp, struct fb_info *fb,
> +		    struct mdp_blit_req *req);
> +	void (*set_grp_disp)(struct mdp_device *mdp, uint32_t disp_id);
> +};
> +
> +struct class_interface;
> +int register_mdp_client(struct class_interface *class_intf);
> +
> +/**** private client data structs go below this line ***/
> +
> +struct msm_mddi_bridge_platform_data {
> +	/* from board file */
> +	int (*init)(struct msm_mddi_bridge_platform_data *,
> +		    struct msm_mddi_client_data *);
> +	int (*uninit)(struct msm_mddi_bridge_platform_data *,
> +		      struct msm_mddi_client_data *);
> +	/* passed to panel for use by the fb driver */
> +	int (*blank)(struct msm_mddi_bridge_platform_data *,
> +		     struct msm_mddi_client_data *);
> +	int (*unblank)(struct msm_mddi_bridge_platform_data *,
> +		       struct msm_mddi_client_data *);
> +	struct msm_fb_data fb_data;
> +};
> +
> +
> +
> +#endif

-- 
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [PATCH 2/2] drivers: video: msm: add include msm_mdp.h
  2010-04-23 23:20 ` [PATCH 2/2] drivers: video: msm: add include msm_mdp.h Daniel Walker
  2010-04-23 23:32   ` Daniel Walker
@ 2010-04-24  5:25   ` Pavel Machek
  2010-04-26 18:00     ` [PATCH] " Daniel Walker
  1 sibling, 1 reply; 7+ messages in thread
From: Pavel Machek @ 2010-04-24  5:25 UTC (permalink / raw)
  To: Daniel Walker; +Cc: linux-arm-msm

Hi!

> Needed to get the driver to compile ;(
> 
> Signed-off-by: Daniel Walker <dwalker@codeaurora.org>
> ---
>  include/linux/msm_mdp.h |   86 +++++++++++++++++++++++++++++++++++++++++++++++
>  1 files changed, 86 insertions(+), 0 deletions(-)
>  create mode 100644 include/linux/msm_mdp.h
> 

> +	MDP_RGB_565,      // RGB 565 planer

planar? Also avaoid C++ comments here.

> +	MDP_XRGB_8888,    // RGB 888 padded
> +	MDP_Y_CBCR_H2V2,  // Y and CbCr, pseudo planer w/ Cb is in MSB
> +	MDP_ARGB_8888,    // ARGB 888
> +	MDP_RGB_888,      // RGB 888 planer
> +	MDP_Y_CRCB_H2V2,  // Y and CrCb, pseudo planer w/ Cr is in MSB
> +	MDP_YCRYCB_H2V1,  // YCrYCb interleave
> +	MDP_Y_CRCB_H2V1,  // Y and CrCb, pseduo planer w/ Cr is in MSB
> +	MDP_Y_CBCR_H2V1,   // Y and CrCb, pseduo planer w/ Cr is in> MSB

misaligned?

> +	MDP_RGBA_8888,    // ARGB 888
> +	MDP_BGRA_8888,    // ARGB 888

really?

> +struct mdp_rect {
> +	uint32_t x;
> +	uint32_t y;
> +	uint32_t w;
> +	uint32_t h;
> +};

Better just use u32. And u32 x,y,w,h; would be quite enough.

									Pavel
-- 
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html

^ permalink raw reply	[flat|nested] 7+ messages in thread

* [PATCH] drivers: video: msm: add include msm_mdp.h
  2010-04-24  5:25   ` Pavel Machek
@ 2010-04-26 18:00     ` Daniel Walker
  2010-04-26 20:34       ` Pavel Machek
  0 siblings, 1 reply; 7+ messages in thread
From: Daniel Walker @ 2010-04-26 18:00 UTC (permalink / raw)
  To: Pavel Machek; +Cc: linux-arm-msm, Daniel Walker

Hows this?

--

Needed to get the driver to compile ;(

Signed-off-by: Daniel Walker <dwalker@codeaurora.org>
---
 include/linux/msm_mdp.h |   78 +++++++++++++++++++++++++++++++++++++++++++++++
 1 files changed, 78 insertions(+), 0 deletions(-)
 create mode 100644 include/linux/msm_mdp.h

diff --git a/include/linux/msm_mdp.h b/include/linux/msm_mdp.h
new file mode 100644
index 0000000..d11fe0f
--- /dev/null
+++ b/include/linux/msm_mdp.h
@@ -0,0 +1,78 @@
+/* include/linux/msm_mdp.h
+ *
+ * Copyright (C) 2007 Google Incorporated
+ *
+ * This software is licensed under the terms of the GNU General Public
+ * License version 2, as published by the Free Software Foundation, and
+ * may be copied, distributed, and modified under those terms.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ */
+#ifndef _MSM_MDP_H_
+#define _MSM_MDP_H_
+
+#include <linux/types.h>
+
+#define MSMFB_IOCTL_MAGIC 'm'
+#define MSMFB_GRP_DISP          _IOW(MSMFB_IOCTL_MAGIC, 1, unsigned int)
+#define MSMFB_BLIT              _IOW(MSMFB_IOCTL_MAGIC, 2, unsigned int)
+
+enum {
+	MDP_RGB_565,		/* RGB 565 planar */
+	MDP_XRGB_8888,		/* RGB 888 padded */
+	MDP_Y_CBCR_H2V2,	/* Y and CbCr, pseudo planar w/ Cb is in MSB */
+	MDP_ARGB_8888,		/* ARGB 888 */
+	MDP_RGB_888,		/* RGB 888 planar */
+	MDP_Y_CRCB_H2V2,	/* Y and CrCb, pseudo planar w/ Cr is in MSB */
+	MDP_YCRYCB_H2V1,	/* YCrYCb interleave */
+	MDP_Y_CRCB_H2V1,	/* Y and CrCb, pseduo planar w/ Cr is in MSB */
+	MDP_Y_CBCR_H2V1,	/* Y and CrCb, pseduo planar w/ Cr is in MSB */
+	MDP_RGBA_8888,		/* ARGB 888 */
+	MDP_BGRA_8888,		/* ABGR 888 */
+	MDP_IMGTYPE_LIMIT	/* Non valid image type after this enum */
+};
+
+enum {
+	PMEM_IMG,
+	FB_IMG,
+};
+
+/* flag values */
+#define MDP_ROT_NOP	0
+#define MDP_FLIP_LR	0x1
+#define MDP_FLIP_UD	0x2
+#define MDP_ROT_90	0x4
+#define MDP_ROT_180	(MDP_FLIP_UD|MDP_FLIP_LR)
+#define MDP_ROT_270	(MDP_ROT_90|MDP_FLIP_UD|MDP_FLIP_LR)
+#define MDP_DITHER	0x8
+#define MDP_BLUR	0x10
+
+#define MDP_TRANSP_NOP	0xffffffff
+#define MDP_ALPHA_NOP	0xff
+
+struct mdp_rect {
+	u32 x, y, w, h;
+};
+
+struct mdp_img {
+	u32 width, height, format, offset;
+	int memory_id;		/* the file descriptor */
+};
+
+struct mdp_blit_req {
+	struct mdp_img src;
+	struct mdp_img dst;
+	struct mdp_rect src_rect;
+	struct mdp_rect dst_rect;
+	u32 alpha, transp_mask, flags;
+};
+
+struct mdp_blit_req_list {
+	u32 count;
+	struct mdp_blit_req req[];
+};
+
+#endif /* _MSM_MDP_H_ */
-- 
1.6.2.3


^ permalink raw reply related	[flat|nested] 7+ messages in thread

* Re: [PATCH] drivers: video: msm: add include msm_mdp.h
  2010-04-26 18:00     ` [PATCH] " Daniel Walker
@ 2010-04-26 20:34       ` Pavel Machek
  0 siblings, 0 replies; 7+ messages in thread
From: Pavel Machek @ 2010-04-26 20:34 UTC (permalink / raw)
  To: Daniel Walker; +Cc: linux-arm-msm

On Mon 2010-04-26 11:00:41, Daniel Walker wrote:
> Hows this?
> 
> --
> 
> Needed to get the driver to compile ;(
> 
> Signed-off-by: Daniel Walker <dwalker@codeaurora.org>

ACK.

> ---
>  include/linux/msm_mdp.h |   78 +++++++++++++++++++++++++++++++++++++++++++++++
>  1 files changed, 78 insertions(+), 0 deletions(-)
>  create mode 100644 include/linux/msm_mdp.h
> 
> diff --git a/include/linux/msm_mdp.h b/include/linux/msm_mdp.h
> new file mode 100644
> index 0000000..d11fe0f
> --- /dev/null
> +++ b/include/linux/msm_mdp.h
> @@ -0,0 +1,78 @@
> +/* include/linux/msm_mdp.h
> + *
> + * Copyright (C) 2007 Google Incorporated
> + *
> + * This software is licensed under the terms of the GNU General Public
> + * License version 2, as published by the Free Software Foundation, and
> + * may be copied, distributed, and modified under those terms.
> + *
> + * This program is distributed in the hope that it will be useful,
> + * but WITHOUT ANY WARRANTY; without even the implied warranty of
> + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
> + * GNU General Public License for more details.
> + */
> +#ifndef _MSM_MDP_H_
> +#define _MSM_MDP_H_
> +
> +#include <linux/types.h>
> +
> +#define MSMFB_IOCTL_MAGIC 'm'
> +#define MSMFB_GRP_DISP          _IOW(MSMFB_IOCTL_MAGIC, 1, unsigned int)
> +#define MSMFB_BLIT              _IOW(MSMFB_IOCTL_MAGIC, 2, unsigned int)
> +
> +enum {
> +	MDP_RGB_565,		/* RGB 565 planar */
> +	MDP_XRGB_8888,		/* RGB 888 padded */
> +	MDP_Y_CBCR_H2V2,	/* Y and CbCr, pseudo planar w/ Cb is in MSB */
> +	MDP_ARGB_8888,		/* ARGB 888 */
> +	MDP_RGB_888,		/* RGB 888 planar */
> +	MDP_Y_CRCB_H2V2,	/* Y and CrCb, pseudo planar w/ Cr is in MSB */
> +	MDP_YCRYCB_H2V1,	/* YCrYCb interleave */
> +	MDP_Y_CRCB_H2V1,	/* Y and CrCb, pseduo planar w/ Cr is in MSB */
> +	MDP_Y_CBCR_H2V1,	/* Y and CrCb, pseduo planar w/ Cr is in MSB */
> +	MDP_RGBA_8888,		/* ARGB 888 */
> +	MDP_BGRA_8888,		/* ABGR 888 */
> +	MDP_IMGTYPE_LIMIT	/* Non valid image type after this enum */
> +};
> +
> +enum {
> +	PMEM_IMG,
> +	FB_IMG,
> +};
> +
> +/* flag values */
> +#define MDP_ROT_NOP	0
> +#define MDP_FLIP_LR	0x1
> +#define MDP_FLIP_UD	0x2
> +#define MDP_ROT_90	0x4
> +#define MDP_ROT_180	(MDP_FLIP_UD|MDP_FLIP_LR)
> +#define MDP_ROT_270	(MDP_ROT_90|MDP_FLIP_UD|MDP_FLIP_LR)
> +#define MDP_DITHER	0x8
> +#define MDP_BLUR	0x10
> +
> +#define MDP_TRANSP_NOP	0xffffffff
> +#define MDP_ALPHA_NOP	0xff
> +
> +struct mdp_rect {
> +	u32 x, y, w, h;
> +};
> +
> +struct mdp_img {
> +	u32 width, height, format, offset;
> +	int memory_id;		/* the file descriptor */
> +};
> +
> +struct mdp_blit_req {
> +	struct mdp_img src;
> +	struct mdp_img dst;
> +	struct mdp_rect src_rect;
> +	struct mdp_rect dst_rect;
> +	u32 alpha, transp_mask, flags;
> +};
> +
> +struct mdp_blit_req_list {
> +	u32 count;
> +	struct mdp_blit_req req[];
> +};
> +
> +#endif /* _MSM_MDP_H_ */

-- 
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2010-04-26 20:34 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-04-23 23:20 [PATCH 1/2] arm: msm: video: add msm_fb.h Daniel Walker
2010-04-23 23:20 ` [PATCH 2/2] drivers: video: msm: add include msm_mdp.h Daniel Walker
2010-04-23 23:32   ` Daniel Walker
2010-04-24  5:25   ` Pavel Machek
2010-04-26 18:00     ` [PATCH] " Daniel Walker
2010-04-26 20:34       ` Pavel Machek
2010-04-24  5:24 ` [PATCH 1/2] arm: msm: video: add msm_fb.h Pavel Machek

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.