lkml.org 
[lkml]   [2019]   [Dec]   [10]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v2 01/10] PCMCIA/i82092: use dev_<level> instead of printk
On Tue, Dec 10, 2019 at 01:49:02PM +0100, Greg Kroah-Hartman wrote:
> > @@ -417,7 +422,9 @@ static int i82092aa_init(struct pcmcia_socket *sock)
> >
> > static int i82092aa_get_status(struct pcmcia_socket *socket, u_int *value)
> > {
> > - unsigned int sock = container_of(socket, struct socket_info, socket)->number;
> > + struct socket_info *sock_info = container_of(socket, struct socket_info,
> > + socket);
> > + unsigned int sock = sock_info->number;
>
>
> This does not look like a printk cleanup :(
>
> > unsigned int status;
> >
> > enter("i82092aa_get_status");
> > @@ -458,7 +465,9 @@ static int i82092aa_get_status(struct pcmcia_socket *socket, u_int *value)
> >
> > static int i82092aa_set_socket(struct pcmcia_socket *socket, socket_state_t *state)
> > {
> > - unsigned int sock = container_of(socket, struct socket_info, socket)->number;
> > + struct socket_info *sock_info = container_of(socket, struct socket_info,
> > + socket);
> > + unsigned int sock = sock_info->number;
>
> Nor does this :(

... regarding _get_socket() you are right, but here it is required for the
printk cleanup -- to be able to use dev_info(), struct device needs to be
made accessible. So this change seems fine to me.

Thanks,
Dominik

\
 
 \ /
  Last update: 2019-12-10 14:26    [W:0.048 / U:0.252 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site