From: Greg KH <gregkh@suse.de>
To: linux-kernel@vger.kernel.org, sensors@Stimpy.netroedge.com
Cc: johnpol@2ka.mipt.ru
Subject: [PATCH] w1_therm: removed duplicated family id.
Date: Tue, 21 Jun 2005 22:12:07 -0700 [thread overview]
Message-ID: <1119417127267@kroah.com> (raw)
In-Reply-To: <11194171273603@kroah.com>
[PATCH] w1_therm: removed duplicated family id.
We can access family id through w1_family structure.
Signed-off-by: Evgeniy Polyakov <johnpol@2ka.mipt.ru>
---
commit 4e470aa9642d49230bcdfbb393cf5a81da333aba
tree eb4e0f515c3c45236f816532c2bd2ce31ac6cfce
parent c7b2b2a723174d22a743180d5367f0028226031b
author Evgeniy Polyakov <johnpol@2ka.mipt.ru> Fri, 20 May 2005 22:50:33 +0400
committer Greg Kroah-Hartman <gregkh@suse.de> Tue, 21 Jun 2005 21:43:10 -0700
drivers/w1/w1_therm.c | 6 +-----
1 files changed, 1 insertions(+), 5 deletions(-)
diff --git a/drivers/w1/w1_therm.c b/drivers/w1/w1_therm.c
--- a/drivers/w1/w1_therm.c
+++ b/drivers/w1/w1_therm.c
@@ -66,7 +66,6 @@ static struct w1_family w1_therm_family_
struct w1_therm_family_converter
{
- u8 fid;
u8 broken;
u16 reserved;
struct w1_family *f;
@@ -78,17 +77,14 @@ static inline int w1_DS18S20_convert_tem
static struct w1_therm_family_converter w1_therm_families[] = {
{
- .fid = W1_THERM_DS18S20,
.f = &w1_therm_family_DS18S20,
.convert = w1_DS18S20_convert_temp
},
{
- .fid = W1_THERM_DS1822,
.f = &w1_therm_family_DS1822,
.convert = w1_DS18B20_convert_temp
},
{
- .fid = W1_THERM_DS18B20,
.f = &w1_therm_family_DS18B20,
.convert = w1_DS18B20_convert_temp
},
@@ -133,7 +129,7 @@ static inline int w1_convert_temp(u8 rom
int i;
for (i=0; i<sizeof(w1_therm_families)/sizeof(w1_therm_families[0]); ++i)
- if (w1_therm_families[i].fid == fid)
+ if (w1_therm_families[i].f->fid == fid)
return w1_therm_families[i].convert(rom);
return 0;
next prev parent reply other threads:[~2005-06-22 5:26 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-06-22 5:11 [GIT PATCH] W1 patches for 2.6.12 Greg KH
2005-06-22 5:12 ` [PATCH] w1_therm: support for ds18b20, ds1822 thermal sensors Greg KH
2005-06-22 5:12 ` [PATCH] w1: cleanups Greg KH
2005-06-22 5:12 ` [PATCH] w1_smem: support for new simple rom family [0x81 id] Greg KH
2005-06-22 5:12 ` [PATCH] w1: new family structure Greg KH
2005-06-22 5:12 ` Greg KH [this message]
2005-06-22 5:12 ` [PATCH] w1: Cleans up usage of touch_bit/w1_read_bit/w1_write_bit Greg KH
2005-06-22 5:12 ` [PATCH] w1: fix build issues Greg KH
2005-06-22 5:12 ` [PATCH] w1: Adds a sysfs entry (w1_master_search) that allows you to disable/enable periodic searches Greg KH
2005-06-22 5:12 ` [PATCH] w1: Added the triplet w1 master method and changes w1_search() to use it Greg KH
2005-06-22 5:12 ` [PATCH] w1: Adds a default family so that new slave families will show up in sysfs Greg KH
2005-06-22 5:12 ` [PATCH] w1: Updates the w1 documentation (w1.generic) Greg KH
2005-06-22 5:12 ` [PATCH] w1: reconnect feature Greg KH
2005-06-22 5:12 ` [PATCH] w1: fix compiler warnings Greg KH
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=1119417127267@kroah.com \
--to=gregkh@suse.de \
--cc=greg@kroah.com \
--cc=johnpol@2ka.mipt.ru \
--cc=linux-kernel@vger.kernel.org \
--cc=sensors@Stimpy.netroedge.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.