Re: [PATCH v1 04/25] j1939: rename addr.pgn to addr.dst_pgn

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On vr, 05 apr 2019 08:33:52 +0200, David Jander wrote:
> On Thu, 4 Apr 2019 19:54:30 +0200
> Kurt Van Dijck <dev.kurt@xxxxxxxxxxxxxxxxxxxxxx> wrote:
> 
> > On vr, 29 mrt 2019 14:58:38 +0100, Oleksij Rempel wrote:
> > > diff --git a/net/can/j1939/j1939-priv.h b/net/can/j1939/j1939-priv.h
> > > index df058d08fe68..127b4e28b16a 100644
> > > --- a/net/can/j1939/j1939-priv.h
> > > +++ b/net/can/j1939/j1939-priv.h
> > > @@ -113,7 +113,7 @@ struct j1939_ecu *j1939_ecu_get_by_name_locked(struct j1939_priv *priv,
> > >  struct j1939_addr {
> > >  	name_t src_name;
> > >  	name_t dst_name;
> > > -	pgn_t pgn;
> > > +	pgn_t dst_pgn;
> > >  
> > >  	u8 sa;
> > >  	u8 da;  
> > 
> > I considered j1939_addr like a kind of label of a packet. In j1939, a
> > packet has only 1 pgn.
> > I'm curious why you need 2.
> 
> There is only one. It just was renamed from pgn to dst_pgn, probably to make
> clear that it is related to the destination and not the source (which wouldn't
> make any sense).

Well, the PGN describes the packet that the source sends to the destination,
so it's equally related to the source as to the destination.
renaming it didn't clarify for me, in contrary.

I suppose it's nitpicking, so if you all think it's better
understandable like that, then I'm ok too.
It's not visible in userspace anyway.

Kurt



[Index of Archives]     [Automotive Discussions]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [eCos]     [Asterisk Internet PBX]     [Linux API]     [CAN Bus]

  Powered by Linux