* [PATCH] staging: android: logger: use kuid_t instead of uid_t
@ 2013-05-08 10:52 Xiong Zhou
2013-05-08 15:37 ` Greg KH
0 siblings, 1 reply; 3+ messages in thread
From: Xiong Zhou @ 2013-05-08 10:52 UTC (permalink / raw)
To: linux-kernel; +Cc: kernel-team, nnk, john.stultz, gregkh, devel, jencce.kernel
From: Xiong Zhou <jencce.kernel@gmail.com>
Use kuid_t instead of uid_t, to pass the UIDGID_STRICT_TYPE_CHECKS.
Signed-off-by: Xiong Zhou <jencce.kernel@gmail.com>
---
drivers/staging/android/logger.c | 4 ++--
drivers/staging/android/logger.h | 2 +-
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/staging/android/logger.c b/drivers/staging/android/logger.c
index b040200..9bd8747 100644
--- a/drivers/staging/android/logger.c
+++ b/drivers/staging/android/logger.c
@@ -242,7 +242,7 @@ static ssize_t do_read_log_to_user(struct logger_log *log,
* 'log->buffer' which contains the first entry readable by 'euid'
*/
static size_t get_next_entry_by_uid(struct logger_log *log,
- size_t off, uid_t euid)
+ size_t off, kuid_t euid)
{
while (off != log->w_off) {
struct logger_entry *entry;
@@ -251,7 +251,7 @@ static size_t get_next_entry_by_uid(struct logger_log *log,
entry = get_entry_header(log, off, &scratch);
- if (entry->euid == euid)
+ if (uid_eq(entry->euid, euid))
return off;
next_len = sizeof(struct logger_entry) + entry->len;
diff --git a/drivers/staging/android/logger.h b/drivers/staging/android/logger.h
index cc6bbd9..70af7d8 100644
--- a/drivers/staging/android/logger.h
+++ b/drivers/staging/android/logger.h
@@ -66,7 +66,7 @@ struct logger_entry {
__s32 tid;
__s32 sec;
__s32 nsec;
- uid_t euid;
+ kuid_t euid;
char msg[0];
};
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] staging: android: logger: use kuid_t instead of uid_t
2013-05-08 10:52 [PATCH] staging: android: logger: use kuid_t instead of uid_t Xiong Zhou
@ 2013-05-08 15:37 ` Greg KH
2013-05-09 0:58 ` Xiong Zhou
0 siblings, 1 reply; 3+ messages in thread
From: Greg KH @ 2013-05-08 15:37 UTC (permalink / raw)
To: Xiong Zhou; +Cc: linux-kernel, devel, john.stultz, kernel-team, nnk
On Wed, May 08, 2013 at 06:52:48PM +0800, Xiong Zhou wrote:
> From: Xiong Zhou <jencce.kernel@gmail.com>
>
> Use kuid_t instead of uid_t, to pass the UIDGID_STRICT_TYPE_CHECKS.
>
> Signed-off-by: Xiong Zhou <jencce.kernel@gmail.com>
Nice job, I'll queue this up after 3.10-rc1 is out.
greg k-h
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] staging: android: logger: use kuid_t instead of uid_t
2013-05-08 15:37 ` Greg KH
@ 2013-05-09 0:58 ` Xiong Zhou
0 siblings, 0 replies; 3+ messages in thread
From: Xiong Zhou @ 2013-05-09 0:58 UTC (permalink / raw)
To: Greg KH; +Cc: linux-kernel, devel, john.stultz, kernel-team, nnk
Thanks all for reviewing.
xiong
2013/5/8 Greg KH <gregkh@linuxfoundation.org>:
> On Wed, May 08, 2013 at 06:52:48PM +0800, Xiong Zhou wrote:
>> From: Xiong Zhou <jencce.kernel@gmail.com>
>>
>> Use kuid_t instead of uid_t, to pass the UIDGID_STRICT_TYPE_CHECKS.
>>
>> Signed-off-by: Xiong Zhou <jencce.kernel@gmail.com>
>
> Nice job, I'll queue this up after 3.10-rc1 is out.
>
> greg k-h
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2013-05-09 0:58 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-05-08 10:52 [PATCH] staging: android: logger: use kuid_t instead of uid_t Xiong Zhou
2013-05-08 15:37 ` Greg KH
2013-05-09 0:58 ` Xiong Zhou
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®