[PATCH weston 2/2] compositor-drm: don't pass option_connector to create_outputs
Pekka Paalanen
ppaalanen at gmail.com
Mon Feb 6 10:46:34 UTC 2017
On Thu, 2 Feb 2017 14:06:56 +0000
"Ucan, Emre (ADITG/SW1)" <eucan at de.adit-jv.com> wrote:
> The connector option is a part of drm_backend struct.
> Therefore, it is not needed to pass it as an argument
> to create_outputs function.
>
> Signed-off-by: Emre Ucan <eucan at de.adit-jv.com>
> ---
> libweston/compositor-drm.c | 9 ++++-----
> 1 file changed, 4 insertions(+), 5 deletions(-)
>
> diff --git a/libweston/compositor-drm.c b/libweston/compositor-drm.c
> index 6d97b49..7b26e56 100644
> --- a/libweston/compositor-drm.c
> +++ b/libweston/compositor-drm.c
> @@ -2652,8 +2652,7 @@ destroy_sprites(struct drm_backend *backend)
> }
>
> static int
> -create_outputs(struct drm_backend *b, uint32_t option_connector,
> - struct udev_device *drm_device)
> +create_outputs(struct drm_backend *b, struct udev_device *drm_device)
> {
> drmModeConnector *connector;
> drmModeRes *resources;
> @@ -2677,8 +2676,8 @@ create_outputs(struct drm_backend *b, uint32_t option_connector,
> continue;
>
> if (connector->connection == DRM_MODE_CONNECTED &&
> - (option_connector == 0 ||
> - connector->connector_id == option_connector)) {
> + (b->connector == 0 ||
> + connector->connector_id == b->connector)) {
> if (create_output_for_connector(b, resources,
> connector, drm_device) < 0) {
> drmModeFreeConnector(connector);
> @@ -3216,7 +3215,7 @@ drm_backend_create(struct weston_compositor *compositor,
>
> b->connector = config->connector;
>
> - if (create_outputs(b, config->connector, drm_device) < 0) {
> + if (create_outputs(b, drm_device) < 0) {
> weston_log("failed to create output for %s\n", path);
> goto err_udev_input;
> }
Hi,
since the earlier patch that I didn't think was a good idea added the
member to drm_backend, this patch won't apply without it.
Thanks,
pq
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 801 bytes
Desc: OpenPGP digital signature
URL: <https://lists.freedesktop.org/archives/wayland-devel/attachments/20170206/63ad63ad/attachment.sig>
More information about the wayland-devel
mailing list