[{"id":21783,"web_url":"https://patchwork.libcamera.org/comment/21783/","msgid":"<YbkRmyQp4SfWLeY1@pendragon.ideasonboard.com>","date":"2021-12-14T21:50:19","subject":"Re: [libcamera-devel] [PATCH 1/5] media: media.h: Add new media\n\tlink type","submitter":{"id":2,"url":"https://patchwork.libcamera.org/api/people/2/","name":"Laurent Pinchart","email":"laurent.pinchart@ideasonboard.com"},"content":"Hi Daniel,\n\nThank you for the patch.\n\nOn Mon, Dec 13, 2021 at 11:28:45PM +0000, Daniel Scally wrote:\n> To describe in the kernel the connection between devices and their\n> supporting peripherals (for example, a camera sensor and the vcm\n> driving the focusing lens for it), add a new type of media link\n> to introduce the concept of these ancillary links.\n> \n> Signed-off-by: Daniel Scally <djrscally@gmail.com>\n> ---\n> changes since the rfc:\n> \n> \t- Split out into its own patch (mostly so it can be followed by patch\n> \t#3, which corrects some media-core code that is otherwise broken by the\n> \tnew links)\n> \n>  include/uapi/linux/media.h | 1 +\n>  1 file changed, 1 insertion(+)\n> \n> diff --git a/include/uapi/linux/media.h b/include/uapi/linux/media.h\n> index 200fa8462b90..afbae7213d35 100644\n> --- a/include/uapi/linux/media.h\n> +++ b/include/uapi/linux/media.h\n> @@ -226,6 +226,7 @@ struct media_pad_desc {\n>  #define MEDIA_LNK_FL_LINK_TYPE\t\t\t(0xf << 28)\n>  #  define MEDIA_LNK_FL_DATA_LINK\t\t(0 << 28)\n>  #  define MEDIA_LNK_FL_INTERFACE_LINK\t\t(1 << 28)\n> +#  define MEDIA_LNK_FL_ANCILLARY_LINK\t\t(2 << 28)\n\nThis needs documentation in\nDocumentation/userspace-api/media/mediactl/media-types.rst and in\nmedia-controller-model.rst. The latter should probably be a bit more\ndetailed to explain the use cases with at least one example.\n\n>  \n>  struct media_link_desc {\n>  \tstruct media_pad_desc source;","headers":{"Return-Path":"<libcamera-devel-bounces@lists.libcamera.org>","X-Original-To":"parsemail@patchwork.libcamera.org","Delivered-To":"parsemail@patchwork.libcamera.org","Received":["from lancelot.ideasonboard.com (lancelot.ideasonboard.com\n\t[92.243.16.209])\n\tby patchwork.libcamera.org (Postfix) with ESMTPS id AF832BF415\n\tfor <parsemail@patchwork.libcamera.org>;\n\tTue, 14 Dec 2021 21:50:25 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 268EB608A4;\n\tTue, 14 Dec 2021 22:50:25 +0100 (CET)","from perceval.ideasonboard.com (perceval.ideasonboard.com\n\t[IPv6:2001:4b98:dc2:55:216:3eff:fef7:d647])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id EC8A660117\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tTue, 14 Dec 2021 22:50:22 +0100 (CET)","from pendragon.ideasonboard.com (62-78-145-57.bb.dnainternet.fi\n\t[62.78.145.57])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id 372B18C4;\n\tTue, 14 Dec 2021 22:50:22 +0100 (CET)"],"Authentication-Results":"lancelot.ideasonboard.com;\n\tdkim=fail reason=\"signature verification failed\" (1024-bit key;\n\tunprotected) header.d=ideasonboard.com header.i=@ideasonboard.com\n\theader.b=\"HRBqn3GH\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1639518622;\n\tbh=52C3i2QePa+o3YzlRI28JWYWcIOPIQ5lcMc66Tn0caY=;\n\th=Date:From:To:Cc:Subject:References:In-Reply-To:From;\n\tb=HRBqn3GHyonCFU+E1uwtWGEssgooG0RD0DjV29s1bTwL3IHQ/2gbB9h+jRlj3djcW\n\tTAE+ztSh1oIgS+VOdwqY3bw2yqqVEpkA5Sm9HIL2rKO96hAOYz/6PB26K7yEpiP7wU\n\tWPyYZ9LlkU/ueUKY++J6eyiYcLH1o+XDTu4npdjI=","Date":"Tue, 14 Dec 2021 23:50:19 +0200","From":"Laurent Pinchart <laurent.pinchart@ideasonboard.com>","To":"Daniel Scally <djrscally@gmail.com>","Message-ID":"<YbkRmyQp4SfWLeY1@pendragon.ideasonboard.com>","References":"<20211213232849.40071-1-djrscally@gmail.com>\n\t<20211213232849.40071-2-djrscally@gmail.com>","MIME-Version":"1.0","Content-Type":"text/plain; charset=utf-8","Content-Disposition":"inline","In-Reply-To":"<20211213232849.40071-2-djrscally@gmail.com>","Subject":"Re: [libcamera-devel] [PATCH 1/5] media: media.h: Add new media\n\tlink type","X-BeenThere":"libcamera-devel@lists.libcamera.org","X-Mailman-Version":"2.1.29","Precedence":"list","List-Id":"<libcamera-devel.lists.libcamera.org>","List-Unsubscribe":"<https://lists.libcamera.org/options/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=unsubscribe>","List-Archive":"<https://lists.libcamera.org/pipermail/libcamera-devel/>","List-Post":"<mailto:libcamera-devel@lists.libcamera.org>","List-Help":"<mailto:libcamera-devel-request@lists.libcamera.org?subject=help>","List-Subscribe":"<https://lists.libcamera.org/listinfo/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=subscribe>","Cc":"libcamera-devel@lists.libcamera.org, sakari.ailus@linux.intel.com,\n\tlinux-media@vger.kernel.org","Errors-To":"libcamera-devel-bounces@lists.libcamera.org","Sender":"\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"}},{"id":21784,"web_url":"https://patchwork.libcamera.org/comment/21784/","msgid":"<c6fd2bd6-13a7-0993-d9fd-e9e40fb8a5e5@gmail.com>","date":"2021-12-14T21:52:48","subject":"Re: [libcamera-devel] [PATCH 1/5] media: media.h: Add new media\n\tlink type","submitter":{"id":90,"url":"https://patchwork.libcamera.org/api/people/90/","name":"Daniel Scally","email":"djrscally@gmail.com"},"content":"Hi Laurent\n\nOn 14/12/2021 21:50, Laurent Pinchart wrote:\n> Hi Daniel,\n>\n> Thank you for the patch.\n>\n> On Mon, Dec 13, 2021 at 11:28:45PM +0000, Daniel Scally wrote:\n>> To describe in the kernel the connection between devices and their\n>> supporting peripherals (for example, a camera sensor and the vcm\n>> driving the focusing lens for it), add a new type of media link\n>> to introduce the concept of these ancillary links.\n>>\n>> Signed-off-by: Daniel Scally <djrscally@gmail.com>\n>> ---\n>> changes since the rfc:\n>>\n>> \t- Split out into its own patch (mostly so it can be followed by patch\n>> \t#3, which corrects some media-core code that is otherwise broken by the\n>> \tnew links)\n>>\n>>  include/uapi/linux/media.h | 1 +\n>>  1 file changed, 1 insertion(+)\n>>\n>> diff --git a/include/uapi/linux/media.h b/include/uapi/linux/media.h\n>> index 200fa8462b90..afbae7213d35 100644\n>> --- a/include/uapi/linux/media.h\n>> +++ b/include/uapi/linux/media.h\n>> @@ -226,6 +226,7 @@ struct media_pad_desc {\n>>  #define MEDIA_LNK_FL_LINK_TYPE\t\t\t(0xf << 28)\n>>  #  define MEDIA_LNK_FL_DATA_LINK\t\t(0 << 28)\n>>  #  define MEDIA_LNK_FL_INTERFACE_LINK\t\t(1 << 28)\n>> +#  define MEDIA_LNK_FL_ANCILLARY_LINK\t\t(2 << 28)\n> This needs documentation in\n> Documentation/userspace-api/media/mediactl/media-types.rst and in\n> media-controller-model.rst. The latter should probably be a bit more\n> detailed to explain the use cases with at least one example.\n\n\nAgreed - I'll add some for the v2\n\n>\n>>  \n>>  struct media_link_desc {\n>>  \tstruct media_pad_desc source;","headers":{"Return-Path":"<libcamera-devel-bounces@lists.libcamera.org>","X-Original-To":"parsemail@patchwork.libcamera.org","Delivered-To":"parsemail@patchwork.libcamera.org","Received":["from lancelot.ideasonboard.com (lancelot.ideasonboard.com\n\t[92.243.16.209])\n\tby patchwork.libcamera.org (Postfix) with ESMTPS id 7F2E6BDB13\n\tfor <parsemail@patchwork.libcamera.org>;\n\tTue, 14 Dec 2021 21:52:52 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id B44B5608A4;\n\tTue, 14 Dec 2021 22:52:51 +0100 (CET)","from mail-wr1-x433.google.com (mail-wr1-x433.google.com\n\t[IPv6:2a00:1450:4864:20::433])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 7F6C560117\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tTue, 14 Dec 2021 22:52:50 +0100 (CET)","by mail-wr1-x433.google.com with SMTP id e5so1358873wrc.5\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tTue, 14 Dec 2021 13:52:50 -0800 (PST)","from [192.168.0.14]\n\t(cpc141996-chfd3-2-0-cust928.12-3.cable.virginm.net. [86.13.91.161])\n\tby smtp.gmail.com with ESMTPSA id s8sm128314wra.9.2021.12.14.13.52.49\n\t(version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128);\n\tTue, 14 Dec 2021 13:52:49 -0800 (PST)"],"Authentication-Results":"lancelot.ideasonboard.com;\n\tdkim=fail reason=\"signature verification failed\" (2048-bit key;\n\tunprotected) header.d=gmail.com header.i=@gmail.com\n\theader.b=\"Y7xy/zQe\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112;\n\th=subject:to:cc:references:from:message-id:date:user-agent\n\t:mime-version:in-reply-to:content-transfer-encoding:content-language; \n\tbh=g1/eUs76GkqKL8wzidjwYfKZiH07OOFNZ+6VwJ/g578=;\n\tb=Y7xy/zQe39notcQ6SHoZftuCK0HeYFKNGJR8HLGktYgBYQoe+IHy8Wo2hinlFZ/7c5\n\tzte//JWQuB2ar5SZae3twt9DjzyXRx6uDKsxBVHVeIt+1oUsS8ufWxHyIYaZdHSNAmxp\n\tqyCcvjW3Ikzi6Av0kkzKBaSI19BZ5koLr0JbNf6pUKueSYwcN/g0Hdq9/p4gyWXpUUGv\n\tlbS9UDui3rxt6ubs9D09NGBhaJPxSYC6jgjw3avZSEe3KF47vIMmcq/sITbkHnb/NXLe\n\tXsCj1JfCejwaGPoOiI7nwTufSzHu+lYKd+oUpfr2yqo/zOz0Xyr7qtz3msLqZXuxyjmM\n\tGkQA==","X-Google-DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=1e100.net; s=20210112;\n\th=x-gm-message-state:subject:to:cc:references:from:message-id:date\n\t:user-agent:mime-version:in-reply-to:content-transfer-encoding\n\t:content-language;\n\tbh=g1/eUs76GkqKL8wzidjwYfKZiH07OOFNZ+6VwJ/g578=;\n\tb=koQqs0t5kEJCTrkI4nk1I+sHkF/sMcM94YRkch4jI7e7K5ZSlpkBYvsZecKMaZm1DN\n\tb1HO6+nUmGTvL7RiJhQDQKT15e6KvQDVLXKFEBZG6GSjw16/3+1kwdRRLE9I4xkJj+Z5\n\t7swpcl5JqB+bZqIJ1dHpAbgVpHYCWhxTF8EqCVw+BRikCjB2sq4bfb1gHTqG+WvmLRK/\n\tqxfm6sE5Yr81pp2bEIClfw7eb/68+o56EB3B5G01xYT+HsstotCobRQNgsYv+u4sq9vV\n\t72U9ytbtWLOKY0TfwdkLU1UN1au2JyEwfCtJv9bySnTmx+zMFcQNgLQoDkn8/ln47zrI\n\tjYlQ==","X-Gm-Message-State":"AOAM532hIqQSIY94BvUL1u4lMxo6ziiKGfj1V8/x1yqFfVAURYz/kHe7\n\tZ5OU+PWaLAdIN1Y4A9kNBlE=","X-Google-Smtp-Source":"ABdhPJwv0Yr7VA5Zfi3/Y+CZ7YPetFqoxAon1DTje7RFjOaWRyitDts/n+IkuBvCKLTL6elMqUlHQQ==","X-Received":"by 2002:a5d:648d:: with SMTP id\n\to13mr1691884wri.636.1639518770258; \n\tTue, 14 Dec 2021 13:52:50 -0800 (PST)","To":"Laurent Pinchart <laurent.pinchart@ideasonboard.com>","References":"<20211213232849.40071-1-djrscally@gmail.com>\n\t<20211213232849.40071-2-djrscally@gmail.com>\n\t<YbkRmyQp4SfWLeY1@pendragon.ideasonboard.com>","From":"Daniel Scally <djrscally@gmail.com>","Message-ID":"<c6fd2bd6-13a7-0993-d9fd-e9e40fb8a5e5@gmail.com>","Date":"Tue, 14 Dec 2021 21:52:48 +0000","User-Agent":"Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101\n\tThunderbird/78.14.0","MIME-Version":"1.0","In-Reply-To":"<YbkRmyQp4SfWLeY1@pendragon.ideasonboard.com>","Content-Type":"text/plain; charset=utf-8","Content-Transfer-Encoding":"7bit","Content-Language":"en-US","Subject":"Re: [libcamera-devel] [PATCH 1/5] media: media.h: Add new media\n\tlink type","X-BeenThere":"libcamera-devel@lists.libcamera.org","X-Mailman-Version":"2.1.29","Precedence":"list","List-Id":"<libcamera-devel.lists.libcamera.org>","List-Unsubscribe":"<https://lists.libcamera.org/options/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=unsubscribe>","List-Archive":"<https://lists.libcamera.org/pipermail/libcamera-devel/>","List-Post":"<mailto:libcamera-devel@lists.libcamera.org>","List-Help":"<mailto:libcamera-devel-request@lists.libcamera.org?subject=help>","List-Subscribe":"<https://lists.libcamera.org/listinfo/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=subscribe>","Cc":"libcamera-devel@lists.libcamera.org, sakari.ailus@linux.intel.com,\n\tlinux-media@vger.kernel.org","Errors-To":"libcamera-devel-bounces@lists.libcamera.org","Sender":"\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"}}]