Subversion Repositories Kolibri OS

Rev

Rev 6936 | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 6936 Rev 7143
Line 94... Line 94...
94
 
94
 
95
/**
95
/**
96
 * struct mipi_dsi_host - DSI host device
96
 * struct mipi_dsi_host - DSI host device
97
 * @dev: driver model device node for this DSI host
97
 * @dev: driver model device node for this DSI host
-
 
98
 * @ops: DSI host operations
98
 * @ops: DSI host operations
99
 * @list: list management
99
 */
100
 */
100
struct mipi_dsi_host {
101
struct mipi_dsi_host {
101
	struct device *dev;
102
	struct device *dev;
-
 
103
	const struct mipi_dsi_host_ops *ops;
102
	const struct mipi_dsi_host_ops *ops;
104
	struct list_head list;
Line 103... Line 105...
103
};
105
};
104
 
106
 
-
 
107
int mipi_dsi_host_register(struct mipi_dsi_host *host);
Line 105... Line 108...
105
int mipi_dsi_host_register(struct mipi_dsi_host *host);
108
void mipi_dsi_host_unregister(struct mipi_dsi_host *host);
Line 106... Line 109...
106
void mipi_dsi_host_unregister(struct mipi_dsi_host *host);
109
struct mipi_dsi_host *of_find_mipi_dsi_host_by_node(struct device_node *node);
107
 
110
 
Line 137... Line 140...
137
	MIPI_DSI_FMT_RGB666,
140
	MIPI_DSI_FMT_RGB666,
138
	MIPI_DSI_FMT_RGB666_PACKED,
141
	MIPI_DSI_FMT_RGB666_PACKED,
139
	MIPI_DSI_FMT_RGB565,
142
	MIPI_DSI_FMT_RGB565,
140
};
143
};
Line -... Line 144...
-
 
144
 
-
 
145
#define DSI_DEV_NAME_SIZE		20
-
 
146
 
-
 
147
/**
-
 
148
 * struct mipi_dsi_device_info - template for creating a mipi_dsi_device
-
 
149
 * @type: DSI peripheral chip type
-
 
150
 * @channel: DSI virtual channel assigned to peripheral
-
 
151
 * @node: pointer to OF device node or NULL
-
 
152
 *
-
 
153
 * This is populated and passed to mipi_dsi_device_new to create a new
-
 
154
 * DSI device
-
 
155
 */
-
 
156
struct mipi_dsi_device_info {
-
 
157
	char type[DSI_DEV_NAME_SIZE];
-
 
158
	u32 channel;
-
 
159
	struct device_node *node;
-
 
160
};
141
 
161
 
142
/**
162
/**
143
 * struct mipi_dsi_device - DSI peripheral device
163
 * struct mipi_dsi_device - DSI peripheral device
144
 * @host: DSI host for this peripheral
164
 * @host: DSI host for this peripheral
-
 
165
 * @dev: driver model device node for this peripheral
145
 * @dev: driver model device node for this peripheral
166
 * @name: DSI peripheral chip type
146
 * @channel: virtual channel assigned to the peripheral
167
 * @channel: virtual channel assigned to the peripheral
147
 * @format: pixel format for video mode
168
 * @format: pixel format for video mode
148
 * @lanes: number of active data lanes
169
 * @lanes: number of active data lanes
149
 * @mode_flags: DSI operation mode related flags
170
 * @mode_flags: DSI operation mode related flags
150
 */
171
 */
151
struct mipi_dsi_device {
172
struct mipi_dsi_device {
152
	struct mipi_dsi_host *host;
173
	struct mipi_dsi_host *host;
Line -... Line 174...
-
 
174
	struct device dev;
153
	struct device dev;
175
 
154
 
176
	char name[DSI_DEV_NAME_SIZE];
155
	unsigned int channel;
177
	unsigned int channel;
156
	unsigned int lanes;
178
	unsigned int lanes;
157
	enum mipi_dsi_pixel_format format;
179
	enum mipi_dsi_pixel_format format;
Line 186... Line 208...
186
	}
208
	}
Line 187... Line 209...
187
 
209
 
188
	return -EINVAL;
210
	return -EINVAL;
Line -... Line 211...
-
 
211
}
-
 
212
 
-
 
213
struct mipi_dsi_device *
-
 
214
mipi_dsi_device_register_full(struct mipi_dsi_host *host,
189
}
215
			      const struct mipi_dsi_device_info *info);
190
 
216
void mipi_dsi_device_unregister(struct mipi_dsi_device *dsi);
191
struct mipi_dsi_device *of_find_mipi_dsi_device_by_node(struct device_node *np);
217
struct mipi_dsi_device *of_find_mipi_dsi_device_by_node(struct device_node *np);
192
int mipi_dsi_attach(struct mipi_dsi_device *dsi);
218
int mipi_dsi_attach(struct mipi_dsi_device *dsi);
193
int mipi_dsi_detach(struct mipi_dsi_device *dsi);
219
int mipi_dsi_detach(struct mipi_dsi_device *dsi);