From: David Brownell <david-b@pacbell.net>
To: "Hiremath, Vaibhav" <hvaibhav@ti.com>
Cc: "video4linux-list@redhat.com" <video4linux-list@redhat.com>,
"davinci-linux-open-source-bounces@linux.davincidsp.com"
<davinci-linux-open-source-bounces@linux.davincidsp.com>,
"linux-omap@vger.kernel.org" <linux-omap@vger.kernel.org>,
"Jadav, Brijesh R" <brijesh.j@ti.com>,
"Shah, Hardik" <hardik.shah@ti.com>,
"Hadli, Manjunath" <mrh@ti.com>, "R, Sivaraj" <sivaraj@ti.com>,
"Karicheri, Muralidharan" <m-karicheri2@ti.com>
Subject: Re: [PATCH 2/2] TVP514x Driver with Review comments fixed
Date: Fri, 28 Nov 2008 11:54:05 -0800 [thread overview]
Message-ID: <200811281154.06274.david-b@pacbell.net> (raw)
In-Reply-To: <200811281150.28801.david-b@pacbell.net>
On Friday 28 November 2008, David Brownell wrote:
> On Friday 28 November 2008, Hiremath, Vaibhav wrote:
> > Will have to now think how to differentiate between these
> > two chips and handle this sequence.
>
> That's really easy, the "id" parameter to probe() tells you:
>
> if (strcmp(id->name, "tvp5146") == 0)
> /* original '46 part ... */;
> else if (strmcp(id->name, "tvp5146m2") == 0)
> /* new '46m2 version ... */
> ... etc
... although it's even easier to use id->driver_data to
hold, for example, a bitmask telling various attributes
of that particular device. Examples here:
- does it have the extra '46 registers?
- does it use the original '46 init sequence?
- or the new m2 one?
- or the original '47 init sequence?
- or the new m1 version?
- ...
Another common use of driver_data is to hold a pointer
to a struct holding chip-specific data that doesn't fit
into a simple bitmask.
- Dave
next prev parent reply other threads:[~2008-11-28 19:54 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-11-28 12:43 [PATCH 2/2] TVP514x Driver with Review comments fixed hvaibhav
2008-11-28 16:26 ` David Brownell
2008-11-28 16:33 ` David Brownell
2008-11-28 18:34 ` Hiremath, Vaibhav
2008-11-28 16:52 ` David Brownell
2008-11-28 18:51 ` Hiremath, Vaibhav
2008-11-28 19:50 ` David Brownell
2008-11-28 19:54 ` David Brownell [this message]
2008-12-02 5:39 ` Hiremath, Vaibhav
2008-12-02 6:38 ` David Brownell
2008-12-02 6:49 ` Hiremath, Vaibhav
2008-12-02 8:26 ` David Brownell
2008-12-02 8:34 ` David Brownell
2008-12-02 8:40 ` Hiremath, Vaibhav
[not found] <hvaibhav@ti.com>
2008-11-26 17:05 ` hvaibhav
2008-11-26 17:48 ` Hans Verkuil
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=200811281154.06274.david-b@pacbell.net \
--to=david-b@pacbell.net \
--cc=brijesh.j@ti.com \
--cc=davinci-linux-open-source-bounces@linux.davincidsp.com \
--cc=dbrownell@users.sourceforge.net \
--cc=hardik.shah@ti.com \
--cc=hvaibhav@ti.com \
--cc=linux-omap@vger.kernel.org \
--cc=m-karicheri2@ti.com \
--cc=mrh@ti.com \
--cc=sivaraj@ti.com \
--cc=video4linux-list@redhat.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