From: paul.elder@ideasonboard.com
To: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Cc: linux-media@vger.kernel.org, Rui Miguel Silva <rmfrfs@gmail.com>,
Steve Longerbeam <slongerbeam@gmail.com>,
Philipp Zabel <p.zabel@pengutronix.de>,
Jacopo Mondi <jacopo@jmondi.org>,
kernel@pengutronix.de, linux-imx@nxp.com
Subject: Re: [PATCH 5/6] staging: media: imx: Drop unused helper functions
Date: Thu, 8 Sep 2022 13:12:43 +0900 [thread overview]
Message-ID: <20220908041243.GI1140330@pyrite.rasen.tech> (raw)
In-Reply-To: <20220907200424.32136-6-laurent.pinchart@ideasonboard.com>
On Wed, Sep 07, 2022 at 11:04:23PM +0300, Laurent Pinchart wrote:
> The imx_media_find_subdev_by_fwnode(),
> imx_media_find_subdev_by_devname(), imx_media_pipeline_csi2_channel()
> and imx_media_pipeline_video_device() helper functions are not used.
> Drop them.
>
> Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Reviewed-by: Paul Elder <paul.elder@ideasonboard.com>
> ---
> drivers/staging/media/imx/imx-media-utils.c | 68 ---------------------
> drivers/staging/media/imx/imx-media.h | 10 ---
> 2 files changed, 78 deletions(-)
>
> diff --git a/drivers/staging/media/imx/imx-media-utils.c b/drivers/staging/media/imx/imx-media-utils.c
> index 294c808b2ebe..07770b47e19b 100644
> --- a/drivers/staging/media/imx/imx-media-utils.c
> +++ b/drivers/staging/media/imx/imx-media-utils.c
> @@ -626,36 +626,6 @@ void imx_media_grp_id_to_sd_name(char *sd_name, int sz, u32 grp_id, int ipu_id)
> }
> EXPORT_SYMBOL_GPL(imx_media_grp_id_to_sd_name);
>
> -struct v4l2_subdev *
> -imx_media_find_subdev_by_fwnode(struct imx_media_dev *imxmd,
> - struct fwnode_handle *fwnode)
> -{
> - struct v4l2_subdev *sd;
> -
> - list_for_each_entry(sd, &imxmd->v4l2_dev.subdevs, list) {
> - if (sd->fwnode == fwnode)
> - return sd;
> - }
> -
> - return NULL;
> -}
> -EXPORT_SYMBOL_GPL(imx_media_find_subdev_by_fwnode);
> -
> -struct v4l2_subdev *
> -imx_media_find_subdev_by_devname(struct imx_media_dev *imxmd,
> - const char *devname)
> -{
> - struct v4l2_subdev *sd;
> -
> - list_for_each_entry(sd, &imxmd->v4l2_dev.subdevs, list) {
> - if (!strcmp(devname, dev_name(sd->dev)))
> - return sd;
> - }
> -
> - return NULL;
> -}
> -EXPORT_SYMBOL_GPL(imx_media_find_subdev_by_devname);
> -
> /*
> * Adds a video device to the master video device list. This is called
> * when a video device is registered.
> @@ -756,25 +726,6 @@ find_pipeline_entity(struct media_entity *start, u32 grp_id,
> return pad ? pad->entity : NULL;
> }
>
> -/*
> - * Find the upstream mipi-csi2 virtual channel reached from the given
> - * start entity in the current pipeline.
> - * Must be called with mdev->graph_mutex held.
> - */
> -int imx_media_pipeline_csi2_channel(struct media_entity *start_entity)
> -{
> - struct media_pad *pad;
> - int ret = -EPIPE;
> -
> - pad = imx_media_pipeline_pad(start_entity, IMX_MEDIA_GRP_ID_CSI2,
> - 0, true);
> - if (pad)
> - ret = pad->index - 1;
> -
> - return ret;
> -}
> -EXPORT_SYMBOL_GPL(imx_media_pipeline_csi2_channel);
> -
> /*
> * Find a subdev reached upstream from the given start entity in
> * the current pipeline.
> @@ -794,25 +745,6 @@ imx_media_pipeline_subdev(struct media_entity *start_entity, u32 grp_id,
> }
> EXPORT_SYMBOL_GPL(imx_media_pipeline_subdev);
>
> -/*
> - * Find a subdev reached upstream from the given start entity in
> - * the current pipeline.
> - * Must be called with mdev->graph_mutex held.
> - */
> -struct video_device *
> -imx_media_pipeline_video_device(struct media_entity *start_entity,
> - enum v4l2_buf_type buftype, bool upstream)
> -{
> - struct media_entity *me;
> -
> - me = find_pipeline_entity(start_entity, 0, buftype, upstream);
> - if (!me)
> - return ERR_PTR(-ENODEV);
> -
> - return media_entity_to_video_device(me);
> -}
> -EXPORT_SYMBOL_GPL(imx_media_pipeline_video_device);
> -
> /*
> * Find a fwnode endpoint that maps to the given subdevice's pad.
> * If there are multiple endpoints that map to the pad, only the
> diff --git a/drivers/staging/media/imx/imx-media.h b/drivers/staging/media/imx/imx-media.h
> index 5e794f291da6..5a1436dbb12d 100644
> --- a/drivers/staging/media/imx/imx-media.h
> +++ b/drivers/staging/media/imx/imx-media.h
> @@ -201,24 +201,14 @@ int imx_media_mbus_fmt_to_pix_fmt(struct v4l2_pix_format *pix,
> const struct imx_media_pixfmt *cc);
> void imx_media_grp_id_to_sd_name(char *sd_name, int sz,
> u32 grp_id, int ipu_id);
> -struct v4l2_subdev *
> -imx_media_find_subdev_by_fwnode(struct imx_media_dev *imxmd,
> - struct fwnode_handle *fwnode);
> -struct v4l2_subdev *
> -imx_media_find_subdev_by_devname(struct imx_media_dev *imxmd,
> - const char *devname);
> void imx_media_add_video_device(struct imx_media_dev *imxmd,
> struct imx_media_video_dev *vdev);
> -int imx_media_pipeline_csi2_channel(struct media_entity *start_entity);
> struct media_pad *
> imx_media_pipeline_pad(struct media_entity *start_entity, u32 grp_id,
> enum v4l2_buf_type buftype, bool upstream);
> struct v4l2_subdev *
> imx_media_pipeline_subdev(struct media_entity *start_entity, u32 grp_id,
> bool upstream);
> -struct video_device *
> -imx_media_pipeline_video_device(struct media_entity *start_entity,
> - enum v4l2_buf_type buftype, bool upstream);
> struct fwnode_handle *imx_media_get_pad_fwnode(struct media_pad *pad);
>
> struct imx_media_dma_buf {
next prev parent reply other threads:[~2022-09-08 4:12 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-09-07 20:04 [PATCH 0/6] media: imx: imx7-media-csi: Destage driver Laurent Pinchart
2022-09-07 20:04 ` [PATCH 1/6] media: imx: Decouple imx8mq-mipi-csi2 from imx7-media-csi Laurent Pinchart
2022-09-08 3:58 ` paul.elder
2022-09-09 18:22 ` Laurent Pinchart
2022-09-13 15:10 ` Martin Kepplinger
2022-09-13 15:26 ` Laurent Pinchart
2022-09-07 20:04 ` [PATCH 2/6] media: imx: Unstage the imx7-media-csi driver Laurent Pinchart
2022-09-08 4:04 ` paul.elder
2022-09-08 15:06 ` Rui Miguel Silva
2022-09-08 15:18 ` Laurent Pinchart
2022-09-08 15:46 ` Rui Miguel Silva
2022-09-07 20:04 ` [PATCH 3/6] staging: media: imx: Drop imx_media_subdev_bound() Laurent Pinchart
2022-09-08 4:08 ` paul.elder
2022-09-07 20:04 ` [PATCH 4/6] staging: media: imx: Drop IMX_MEDIA_GRP_ID_CSI Laurent Pinchart
2022-09-08 4:10 ` paul.elder
2022-09-07 20:04 ` [PATCH 5/6] staging: media: imx: Drop unused helper functions Laurent Pinchart
2022-09-08 4:12 ` paul.elder [this message]
2022-09-07 20:04 ` [PATCH 6/6] staging: media: imx: Make imx_media_of_add_csi() static Laurent Pinchart
2022-09-08 4:16 ` paul.elder
2022-09-13 9:48 ` [PATCH 0/6] media: imx: imx7-media-csi: Destage driver Alexander Stein
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20220908041243.GI1140330@pyrite.rasen.tech \
--to=paul.elder@ideasonboard.com \
--cc=jacopo@jmondi.org \
--cc=kernel@pengutronix.de \
--cc=laurent.pinchart@ideasonboard.com \
--cc=linux-imx@nxp.com \
--cc=linux-media@vger.kernel.org \
--cc=p.zabel@pengutronix.de \
--cc=rmfrfs@gmail.com \
--cc=slongerbeam@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox