Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
linux
Commits
c79bea07
Commit
c79bea07
authored
Apr 19, 2005
by
Linus Torvalds
Browse files
Options
Browse Files
Download
Plain Diff
Merge master.kernel.org:/pub/scm/linux/kernel/git/gregkh/i2c-2.6.git/
parents
a9e4820c
1d66c64c
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
10 additions
and
10 deletions
+10
-10
drivers/i2c/chips/it87.c
drivers/i2c/chips/it87.c
+1
-1
drivers/i2c/chips/via686a.c
drivers/i2c/chips/via686a.c
+2
-3
drivers/w1/w1.c
drivers/w1/w1.c
+5
-4
drivers/w1/w1_smem.c
drivers/w1/w1_smem.c
+2
-2
No files found.
drivers/i2c/chips/it87.c
View file @
c79bea07
...
@@ -668,7 +668,7 @@ static ssize_t show_alarms(struct device *dev, char *buf)
...
@@ -668,7 +668,7 @@ static ssize_t show_alarms(struct device *dev, char *buf)
struct
it87_data
*
data
=
it87_update_device
(
dev
);
struct
it87_data
*
data
=
it87_update_device
(
dev
);
return
sprintf
(
buf
,
"%d
\n
"
,
ALARMS_FROM_REG
(
data
->
alarms
));
return
sprintf
(
buf
,
"%d
\n
"
,
ALARMS_FROM_REG
(
data
->
alarms
));
}
}
static
DEVICE_ATTR
(
alarms
,
S_IRUGO
|
S_IWUSR
,
show_alarms
,
NULL
);
static
DEVICE_ATTR
(
alarms
,
S_IRUGO
,
show_alarms
,
NULL
);
static
ssize_t
static
ssize_t
show_vrm_reg
(
struct
device
*
dev
,
char
*
buf
)
show_vrm_reg
(
struct
device
*
dev
,
char
*
buf
)
...
...
drivers/i2c/chips/via686a.c
View file @
c79bea07
...
@@ -574,7 +574,7 @@ static ssize_t show_alarms(struct device *dev, char *buf) {
...
@@ -574,7 +574,7 @@ static ssize_t show_alarms(struct device *dev, char *buf) {
struct
via686a_data
*
data
=
via686a_update_device
(
dev
);
struct
via686a_data
*
data
=
via686a_update_device
(
dev
);
return
sprintf
(
buf
,
"%d
\n
"
,
ALARMS_FROM_REG
(
data
->
alarms
));
return
sprintf
(
buf
,
"%d
\n
"
,
ALARMS_FROM_REG
(
data
->
alarms
));
}
}
static
DEVICE_ATTR
(
alarms
,
S_IRUGO
|
S_IWUSR
,
show_alarms
,
NULL
);
static
DEVICE_ATTR
(
alarms
,
S_IRUGO
,
show_alarms
,
NULL
);
/* The driver. I choose to use type i2c_driver, as at is identical to both
/* The driver. I choose to use type i2c_driver, as at is identical to both
smbus_driver and isa_driver, and clients could be of either kind */
smbus_driver and isa_driver, and clients could be of either kind */
...
@@ -651,10 +651,9 @@ static int via686a_detect(struct i2c_adapter *adapter, int address, int kind)
...
@@ -651,10 +651,9 @@ static int via686a_detect(struct i2c_adapter *adapter, int address, int kind)
new_client
->
adapter
=
adapter
;
new_client
->
adapter
=
adapter
;
new_client
->
driver
=
&
via686a_driver
;
new_client
->
driver
=
&
via686a_driver
;
new_client
->
flags
=
0
;
new_client
->
flags
=
0
;
new_client
->
dev
.
parent
=
&
adapter
->
dev
;
/* Fill in the remaining client fields and put into the global list */
/* Fill in the remaining client fields and put into the global list */
s
nprintf
(
new_client
->
name
,
I2C_NAME_SIZE
,
client_name
);
s
trlcpy
(
new_client
->
name
,
client_name
,
I2C_NAME_SIZE
);
data
->
valid
=
0
;
data
->
valid
=
0
;
init_MUTEX
(
&
data
->
update_lock
);
init_MUTEX
(
&
data
->
update_lock
);
...
...
drivers/w1/w1.c
View file @
c79bea07
...
@@ -522,10 +522,11 @@ void w1_slave_found(unsigned long data, u64 rn)
...
@@ -522,10 +522,11 @@ void w1_slave_found(unsigned long data, u64 rn)
slave_count
++
;
slave_count
++
;
}
}
if
(
slave_count
==
dev
->
slave_count
&&
rn
)
{
rn
=
cpu_to_le64
(
rn
);
tmp
=
cpu_to_le64
(
rn
);
if
(((
rn
>>
56
)
&
0xff
)
==
w1_calc_crc8
((
u8
*
)
&
tmp
,
7
))
if
(
slave_count
==
dev
->
slave_count
&&
w1_attach_slave_device
(
dev
,
(
struct
w1_reg_num
*
)
&
rn
);
rn
&&
((
le64_to_cpu
(
rn
)
>>
56
)
&
0xff
)
==
w1_calc_crc8
((
u8
*
)
&
rn
,
7
))
{
w1_attach_slave_device
(
dev
,
tmp
);
}
}
atomic_dec
(
&
dev
->
refcnt
);
atomic_dec
(
&
dev
->
refcnt
);
...
...
drivers/w1/w1_smem.c
View file @
c79bea07
...
@@ -60,7 +60,7 @@ static ssize_t w1_smem_read_val(struct device *dev, char *buf)
...
@@ -60,7 +60,7 @@ static ssize_t w1_smem_read_val(struct device *dev, char *buf)
int
i
;
int
i
;
ssize_t
count
=
0
;
ssize_t
count
=
0
;
for
(
i
=
0
;
i
<
9
;
++
i
)
for
(
i
=
0
;
i
<
8
;
++
i
)
count
+=
sprintf
(
buf
+
count
,
"%02x "
,
((
u8
*
)
&
sl
->
reg_num
)[
i
]);
count
+=
sprintf
(
buf
+
count
,
"%02x "
,
((
u8
*
)
&
sl
->
reg_num
)[
i
]);
count
+=
sprintf
(
buf
+
count
,
"
\n
"
);
count
+=
sprintf
(
buf
+
count
,
"
\n
"
);
...
@@ -87,7 +87,7 @@ static ssize_t w1_smem_read_bin(struct kobject *kobj, char *buf, loff_t off, siz
...
@@ -87,7 +87,7 @@ static ssize_t w1_smem_read_bin(struct kobject *kobj, char *buf, loff_t off, siz
count
=
0
;
count
=
0
;
goto
out
;
goto
out
;
}
}
for
(
i
=
0
;
i
<
9
;
++
i
)
for
(
i
=
0
;
i
<
8
;
++
i
)
count
+=
sprintf
(
buf
+
count
,
"%02x "
,
((
u8
*
)
&
sl
->
reg_num
)[
i
]);
count
+=
sprintf
(
buf
+
count
,
"%02x "
,
((
u8
*
)
&
sl
->
reg_num
)[
i
]);
count
+=
sprintf
(
buf
+
count
,
"
\n
"
);
count
+=
sprintf
(
buf
+
count
,
"
\n
"
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment