From: Adrien Thierry <athierry@redhat.com>
To: Stefan Wahren <stefan.wahren@i2se.com>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
Florian Fainelli <f.fainelli@gmail.com>,
Ray Jui <rjui@broadcom.com>,
Scott Branden <sbranden@broadcom.com>,
bcm-kernel-feedback-list@broadcom.com,
Nicolas Saenz Julienne <nsaenz@kernel.org>,
linux-staging@lists.linux.dev,
linux-rpi-kernel@lists.infradead.org,
linux-arm-kernel@lists.infradead.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH 2/3] staging: vchiq_arm: get rid of global device structure
Date: Thu, 5 May 2022 14:11:10 -0400 [thread overview]
Message-ID: <YnQTPmNAvpbQl5Ws@fedora> (raw)
In-Reply-To: <8483a250-da97-1875-4ea3-598f46ae96ce@i2se.com>
Hi Stefan,
Thanks for your feedback.
> i understand the motivation, but could you please explain more in detail
> why you decided to add vchiq_instance instead of device reference? I
> think vchiq_instance is a more internal structure which should be
> avoided in kernel consumers like bcm2835-audio or mmal.
I used the vchiq_instance instead of the device reference because in order
to get rid of the vchiq_states array (patch 3/3 [1]), I needed another way
to access the vchiq_state in the 'handle_to_service' function. So I passed
the vchiq_instance to it (I could also have passed the state directly
instead of the instance), and this propagated in the caller chain all the
way up to 'vchiq_bulk_transmit' and friends which are used in the
bcm2835-audio consumer. Please let me know if you see a better way of
doing this :)
Thanks,
Adrien
[1] https://lore.kernel.org/all/20220502183045.206519-4-athierry@redhat.com/
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
next prev parent reply other threads:[~2022-05-05 18:12 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-05-02 18:30 [PATCH 0/3] staging: vchiq_arm: remove some unnecessary global Adrien Thierry
2022-05-02 18:30 ` [PATCH 1/3] staging: vchiq_arm: add reference to vchiq device in vchiq_state Adrien Thierry
2022-05-04 14:53 ` Stefan Wahren
2022-05-05 18:13 ` Adrien Thierry
2022-05-02 18:30 ` [PATCH 2/3] staging: vchiq_arm: get rid of global device structure Adrien Thierry
2022-05-04 15:05 ` Stefan Wahren
2022-05-05 18:11 ` Adrien Thierry [this message]
2022-05-09 10:51 ` Stefan Wahren
2022-05-02 18:30 ` [PATCH 3/3] staging: vchiq_arm: get rid of global vchiq_states array Adrien Thierry
2022-05-04 15:10 ` Stefan Wahren
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=YnQTPmNAvpbQl5Ws@fedora \
--to=athierry@redhat.com \
--cc=bcm-kernel-feedback-list@broadcom.com \
--cc=f.fainelli@gmail.com \
--cc=gregkh@linuxfoundation.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-rpi-kernel@lists.infradead.org \
--cc=linux-staging@lists.linux.dev \
--cc=nsaenz@kernel.org \
--cc=rjui@broadcom.com \
--cc=sbranden@broadcom.com \
--cc=stefan.wahren@i2se.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;
as well as URLs for NNTP newsgroup(s).