diff mbox

Disable packet offset adjustments on head push/pull as requested by Petri

Message ID 1418754691-32192-1-git-send-email-bill.fischofer@linaro.org
State New
Headers show

Commit Message

Bill Fischofer Dec. 16, 2014, 6:31 p.m. UTC
Signed-off-by: Bill Fischofer <bill.fischofer@linaro.org>
---
Note: This patch pre-reqs https://patches.linaro.org/42346/

 platform/linux-generic/include/odp_packet_internal.h | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

Comments

Anders Roxell Dec. 16, 2014, 11:34 p.m. UTC | #1
Don't put peoples name in the commit message.
The short log informs what it affects and fixes in 50 - 65 chars

An earlier email described the standard what we resolved:
(linux-generic|api|doc|validation|example): file/func: short desc.

This is the long description!

Signed-off-by: ...
---


Cheers,
Anders

On 16 December 2014 at 19:31, Bill Fischofer <bill.fischofer@linaro.org> wrote:
> Signed-off-by: Bill Fischofer <bill.fischofer@linaro.org>
> ---
> Note: This patch pre-reqs https://patches.linaro.org/42346/
>
>  platform/linux-generic/include/odp_packet_internal.h | 6 ++++--
>  1 file changed, 4 insertions(+), 2 deletions(-)
>
> diff --git a/platform/linux-generic/include/odp_packet_internal.h b/platform/linux-generic/include/odp_packet_internal.h
> index 515c127..068f969 100644
> --- a/platform/linux-generic/include/odp_packet_internal.h
> +++ b/platform/linux-generic/include/odp_packet_internal.h
> @@ -198,13 +198,15 @@ static inline void *packet_map(odp_packet_hdr_t *pkt_hdr,
>                           pkt_hdr->headroom + pkt_hdr->frame_len);
>  }
>
> +#define ENABLE_OFFSET_UPDATES 0
> +
>  #define pull_offset(x, len) do { \
> -       if (x != ODP_PACKET_OFFSET_INVALID) \
> +       if (ENABLE_OFFSET_UPDATES && x != ODP_PACKET_OFFSET_INVALID) \
>                 x = x < len ? ODP_PACKET_OFFSET_INVALID : x - len; \
>         } while (0)
>
>  #define push_offset(x, len) do { \
> -       if (x != ODP_PACKET_OFFSET_INVALID) \
> +       if (ENABLE_OFFSET_UPDATES && x != ODP_PACKET_OFFSET_INVALID) \
>                 x += len; \
>         } while (0)
>
> --
> 1.8.3.2
>
>
> _______________________________________________
> lng-odp mailing list
> lng-odp@lists.linaro.org
> http://lists.linaro.org/mailman/listinfo/lng-odp
Bill Fischofer Dec. 17, 2014, 1:43 a.m. UTC | #2
The subject is a single line.  It is short.  I see no rules saying anything
about names.  It explains why the patch is being done.

On Tue, Dec 16, 2014 at 5:34 PM, Anders Roxell <anders.roxell@linaro.org>
wrote:
>
> Don't put peoples name in the commit message.
> The short log informs what it affects and fixes in 50 - 65 chars
>
> An earlier email described the standard what we resolved:
> (linux-generic|api|doc|validation|example): file/func: short desc.
>
> This is the long description!
>
> Signed-off-by: ...
> ---
>
>
> Cheers,
> Anders
>
> On 16 December 2014 at 19:31, Bill Fischofer <bill.fischofer@linaro.org>
> wrote:
> > Signed-off-by: Bill Fischofer <bill.fischofer@linaro.org>
> > ---
> > Note: This patch pre-reqs https://patches.linaro.org/42346/
> >
> >  platform/linux-generic/include/odp_packet_internal.h | 6 ++++--
> >  1 file changed, 4 insertions(+), 2 deletions(-)
> >
> > diff --git a/platform/linux-generic/include/odp_packet_internal.h
> b/platform/linux-generic/include/odp_packet_internal.h
> > index 515c127..068f969 100644
> > --- a/platform/linux-generic/include/odp_packet_internal.h
> > +++ b/platform/linux-generic/include/odp_packet_internal.h
> > @@ -198,13 +198,15 @@ static inline void *packet_map(odp_packet_hdr_t
> *pkt_hdr,
> >                           pkt_hdr->headroom + pkt_hdr->frame_len);
> >  }
> >
> > +#define ENABLE_OFFSET_UPDATES 0
> > +
> >  #define pull_offset(x, len) do { \
> > -       if (x != ODP_PACKET_OFFSET_INVALID) \
> > +       if (ENABLE_OFFSET_UPDATES && x != ODP_PACKET_OFFSET_INVALID) \
> >                 x = x < len ? ODP_PACKET_OFFSET_INVALID : x - len; \
> >         } while (0)
> >
> >  #define push_offset(x, len) do { \
> > -       if (x != ODP_PACKET_OFFSET_INVALID) \
> > +       if (ENABLE_OFFSET_UPDATES && x != ODP_PACKET_OFFSET_INVALID) \
> >                 x += len; \
> >         } while (0)
> >
> > --
> > 1.8.3.2
> >
> >
> > _______________________________________________
> > lng-odp mailing list
> > lng-odp@lists.linaro.org
> > http://lists.linaro.org/mailman/listinfo/lng-odp
>
Maxim Uvarov Dec. 17, 2014, 4:50 p.m. UTC | #3
On 12/17/2014 04:43 AM, Bill Fischofer wrote:
> The subject is a single line.  It is short.  I see no rules saying 
> anything about names.  It explains why the patch is being done.
>

Agree with Anders here. "as requested by Petri" should not be in git commit.

Maxim.

> On Tue, Dec 16, 2014 at 5:34 PM, Anders Roxell 
> <anders.roxell@linaro.org <mailto:anders.roxell@linaro.org>> wrote:
>
>     Don't put peoples name in the commit message.
>     The short log informs what it affects and fixes in 50 - 65 chars
>
>     An earlier email described the standard what we resolved:
>     (linux-generic|api|doc|validation|example): file/func: short desc.
>
>     This is the long description!
>
>     Signed-off-by: ...
>     ---
>
>
>     Cheers,
>     Anders
>
>     On 16 December 2014 at 19:31, Bill Fischofer
>     <bill.fischofer@linaro.org <mailto:bill.fischofer@linaro.org>> wrote:
>     > Signed-off-by: Bill Fischofer <bill.fischofer@linaro.org
>     <mailto:bill.fischofer@linaro.org>>
>     > ---
>     > Note: This patch pre-reqs https://patches.linaro.org/42346/
>     >
>     > platform/linux-generic/include/odp_packet_internal.h | 6 ++++--
>     >  1 file changed, 4 insertions(+), 2 deletions(-)
>     >
>     > diff --git
>     a/platform/linux-generic/include/odp_packet_internal.h
>     b/platform/linux-generic/include/odp_packet_internal.h
>     > index 515c127..068f969 100644
>     > --- a/platform/linux-generic/include/odp_packet_internal.h
>     > +++ b/platform/linux-generic/include/odp_packet_internal.h
>     > @@ -198,13 +198,15 @@ static inline void
>     *packet_map(odp_packet_hdr_t *pkt_hdr,
>     >                           pkt_hdr->headroom + pkt_hdr->frame_len);
>     >  }
>     >
>     > +#define ENABLE_OFFSET_UPDATES 0
>     > +
>     >  #define pull_offset(x, len) do { \
>     > -       if (x != ODP_PACKET_OFFSET_INVALID) \
>     > +       if (ENABLE_OFFSET_UPDATES && x !=
>     ODP_PACKET_OFFSET_INVALID) \
>     >                 x = x < len ? ODP_PACKET_OFFSET_INVALID : x - len; \
>     >         } while (0)
>     >
>     >  #define push_offset(x, len) do { \
>     > -       if (x != ODP_PACKET_OFFSET_INVALID) \
>     > +       if (ENABLE_OFFSET_UPDATES && x !=
>     ODP_PACKET_OFFSET_INVALID) \
>     >                 x += len; \
>     >         } while (0)
>     >
>     > --
>     > 1.8.3.2
>     >
>     >
>     > _______________________________________________
>     > lng-odp mailing list
>     > lng-odp@lists.linaro.org <mailto:lng-odp@lists.linaro.org>
>     > http://lists.linaro.org/mailman/listinfo/lng-odp
>
>
>
> _______________________________________________
> lng-odp mailing list
> lng-odp@lists.linaro.org
> http://lists.linaro.org/mailman/listinfo/lng-odp
Ola Liljedahl Dec. 17, 2014, 4:56 p.m. UTC | #4
On 17 December 2014 at 17:50, Maxim Uvarov <maxim.uvarov@linaro.org> wrote:
> On 12/17/2014 04:43 AM, Bill Fischofer wrote:
>>
>> The subject is a single line.  It is short.  I see no rules saying
>> anything about names.  It explains why the patch is being done.
>>
>
> Agree with Anders here. "as requested by Petri" should not be in git commit.
This comment should be under the "---". Useful when you look at the
patch on the mailing list today (and might remember any prior patch or
discussion). Not interesting when someone else reads the commit log in
ten years.

-- Ola

>
> Maxim.
>
>> On Tue, Dec 16, 2014 at 5:34 PM, Anders Roxell <anders.roxell@linaro.org
>> <mailto:anders.roxell@linaro.org>> wrote:
>>
>>     Don't put peoples name in the commit message.
>>     The short log informs what it affects and fixes in 50 - 65 chars
>>
>>     An earlier email described the standard what we resolved:
>>     (linux-generic|api|doc|validation|example): file/func: short desc.
>>
>>     This is the long description!
>>
>>     Signed-off-by: ...
>>     ---
>>
>>
>>     Cheers,
>>     Anders
>>
>>     On 16 December 2014 at 19:31, Bill Fischofer
>>     <bill.fischofer@linaro.org <mailto:bill.fischofer@linaro.org>> wrote:
>>     > Signed-off-by: Bill Fischofer <bill.fischofer@linaro.org
>>     <mailto:bill.fischofer@linaro.org>>
>>     > ---
>>     > Note: This patch pre-reqs https://patches.linaro.org/42346/
>>     >
>>     > platform/linux-generic/include/odp_packet_internal.h | 6 ++++--
>>     >  1 file changed, 4 insertions(+), 2 deletions(-)
>>     >
>>     > diff --git
>>     a/platform/linux-generic/include/odp_packet_internal.h
>>     b/platform/linux-generic/include/odp_packet_internal.h
>>     > index 515c127..068f969 100644
>>     > --- a/platform/linux-generic/include/odp_packet_internal.h
>>     > +++ b/platform/linux-generic/include/odp_packet_internal.h
>>     > @@ -198,13 +198,15 @@ static inline void
>>     *packet_map(odp_packet_hdr_t *pkt_hdr,
>>     >                           pkt_hdr->headroom + pkt_hdr->frame_len);
>>     >  }
>>     >
>>     > +#define ENABLE_OFFSET_UPDATES 0
>>     > +
>>     >  #define pull_offset(x, len) do { \
>>     > -       if (x != ODP_PACKET_OFFSET_INVALID) \
>>     > +       if (ENABLE_OFFSET_UPDATES && x !=
>>     ODP_PACKET_OFFSET_INVALID) \
>>     >                 x = x < len ? ODP_PACKET_OFFSET_INVALID : x - len; \
>>     >         } while (0)
>>     >
>>     >  #define push_offset(x, len) do { \
>>     > -       if (x != ODP_PACKET_OFFSET_INVALID) \
>>     > +       if (ENABLE_OFFSET_UPDATES && x !=
>>     ODP_PACKET_OFFSET_INVALID) \
>>     >                 x += len; \
>>     >         } while (0)
>>     >
>>     > --
>>     > 1.8.3.2
>>     >
>>     >
>>     > _______________________________________________
>>     > lng-odp mailing list
>>     > lng-odp@lists.linaro.org <mailto:lng-odp@lists.linaro.org>
>>     > http://lists.linaro.org/mailman/listinfo/lng-odp
>>
>>
>>
>> _______________________________________________
>> lng-odp mailing list
>> lng-odp@lists.linaro.org
>> http://lists.linaro.org/mailman/listinfo/lng-odp
>
>
>
> _______________________________________________
> lng-odp mailing list
> lng-odp@lists.linaro.org
> http://lists.linaro.org/mailman/listinfo/lng-odp
Bill Fischofer Dec. 17, 2014, 5:02 p.m. UTC | #5
These patches were resent yesterday and have been superseded by patches
Petri sent covering the same area.


On Wed, Dec 17, 2014 at 10:56 AM, Ola Liljedahl <ola.liljedahl@linaro.org>
wrote:
>
> On 17 December 2014 at 17:50, Maxim Uvarov <maxim.uvarov@linaro.org>
> wrote:
> > On 12/17/2014 04:43 AM, Bill Fischofer wrote:
> >>
> >> The subject is a single line.  It is short.  I see no rules saying
> >> anything about names.  It explains why the patch is being done.
> >>
> >
> > Agree with Anders here. "as requested by Petri" should not be in git
> commit.
> This comment should be under the "---". Useful when you look at the
> patch on the mailing list today (and might remember any prior patch or
> discussion). Not interesting when someone else reads the commit log in
> ten years.
>
> -- Ola
>
> >
> > Maxim.
> >
> >> On Tue, Dec 16, 2014 at 5:34 PM, Anders Roxell <
> anders.roxell@linaro.org
> >> <mailto:anders.roxell@linaro.org>> wrote:
> >>
> >>     Don't put peoples name in the commit message.
> >>     The short log informs what it affects and fixes in 50 - 65 chars
> >>
> >>     An earlier email described the standard what we resolved:
> >>     (linux-generic|api|doc|validation|example): file/func: short desc.
> >>
> >>     This is the long description!
> >>
> >>     Signed-off-by: ...
> >>     ---
> >>
> >>
> >>     Cheers,
> >>     Anders
> >>
> >>     On 16 December 2014 at 19:31, Bill Fischofer
> >>     <bill.fischofer@linaro.org <mailto:bill.fischofer@linaro.org>>
> wrote:
> >>     > Signed-off-by: Bill Fischofer <bill.fischofer@linaro.org
> >>     <mailto:bill.fischofer@linaro.org>>
> >>     > ---
> >>     > Note: This patch pre-reqs https://patches.linaro.org/42346/
> >>     >
> >>     > platform/linux-generic/include/odp_packet_internal.h | 6 ++++--
> >>     >  1 file changed, 4 insertions(+), 2 deletions(-)
> >>     >
> >>     > diff --git
> >>     a/platform/linux-generic/include/odp_packet_internal.h
> >>     b/platform/linux-generic/include/odp_packet_internal.h
> >>     > index 515c127..068f969 100644
> >>     > --- a/platform/linux-generic/include/odp_packet_internal.h
> >>     > +++ b/platform/linux-generic/include/odp_packet_internal.h
> >>     > @@ -198,13 +198,15 @@ static inline void
> >>     *packet_map(odp_packet_hdr_t *pkt_hdr,
> >>     >                           pkt_hdr->headroom + pkt_hdr->frame_len);
> >>     >  }
> >>     >
> >>     > +#define ENABLE_OFFSET_UPDATES 0
> >>     > +
> >>     >  #define pull_offset(x, len) do { \
> >>     > -       if (x != ODP_PACKET_OFFSET_INVALID) \
> >>     > +       if (ENABLE_OFFSET_UPDATES && x !=
> >>     ODP_PACKET_OFFSET_INVALID) \
> >>     >                 x = x < len ? ODP_PACKET_OFFSET_INVALID : x -
> len; \
> >>     >         } while (0)
> >>     >
> >>     >  #define push_offset(x, len) do { \
> >>     > -       if (x != ODP_PACKET_OFFSET_INVALID) \
> >>     > +       if (ENABLE_OFFSET_UPDATES && x !=
> >>     ODP_PACKET_OFFSET_INVALID) \
> >>     >                 x += len; \
> >>     >         } while (0)
> >>     >
> >>     > --
> >>     > 1.8.3.2
> >>     >
> >>     >
> >>     > _______________________________________________
> >>     > lng-odp mailing list
> >>     > lng-odp@lists.linaro.org <mailto:lng-odp@lists.linaro.org>
> >>     > http://lists.linaro.org/mailman/listinfo/lng-odp
> >>
> >>
> >>
> >> _______________________________________________
> >> lng-odp mailing list
> >> lng-odp@lists.linaro.org
> >> http://lists.linaro.org/mailman/listinfo/lng-odp
> >
> >
> >
> > _______________________________________________
> > lng-odp mailing list
> > lng-odp@lists.linaro.org
> > http://lists.linaro.org/mailman/listinfo/lng-odp
>
> _______________________________________________
> lng-odp mailing list
> lng-odp@lists.linaro.org
> http://lists.linaro.org/mailman/listinfo/lng-odp
>
Maxim Uvarov Dec. 17, 2014, 5:11 p.m. UTC | #6
On 12/17/2014 08:02 PM, Bill Fischofer wrote:
> These patches were resent yesterday and have been superseded by 
> patches Petri sent covering the same area.
>
Can you add review-by to new patch?

Maxim.

>
> On Wed, Dec 17, 2014 at 10:56 AM, Ola Liljedahl 
> <ola.liljedahl@linaro.org <mailto:ola.liljedahl@linaro.org>> wrote:
>
>     On 17 December 2014 at 17:50, Maxim Uvarov
>     <maxim.uvarov@linaro.org <mailto:maxim.uvarov@linaro.org>> wrote:
>     > On 12/17/2014 04:43 AM, Bill Fischofer wrote:
>     >>
>     >> The subject is a single line.  It is short.  I see no rules saying
>     >> anything about names.  It explains why the patch is being done.
>     >>
>     >
>     > Agree with Anders here. "as requested by Petri" should not be in
>     git commit.
>     This comment should be under the "---". Useful when you look at the
>     patch on the mailing list today (and might remember any prior patch or
>     discussion). Not interesting when someone else reads the commit log in
>     ten years.
>
>     -- Ola
>
>     >
>     > Maxim.
>     >
>     >> On Tue, Dec 16, 2014 at 5:34 PM, Anders Roxell
>     <anders.roxell@linaro.org <mailto:anders.roxell@linaro.org>
>     >> <mailto:anders.roxell@linaro.org
>     <mailto:anders.roxell@linaro.org>>> wrote:
>     >>
>     >>     Don't put peoples name in the commit message.
>     >>     The short log informs what it affects and fixes in 50 - 65
>     chars
>     >>
>     >>     An earlier email described the standard what we resolved:
>     >>     (linux-generic|api|doc|validation|example): file/func:
>     short desc.
>     >>
>     >>     This is the long description!
>     >>
>     >>     Signed-off-by: ...
>     >>     ---
>     >>
>     >>
>     >>     Cheers,
>     >>     Anders
>     >>
>     >>     On 16 December 2014 at 19:31, Bill Fischofer
>     >>     <bill.fischofer@linaro.org
>     <mailto:bill.fischofer@linaro.org>
>     <mailto:bill.fischofer@linaro.org
>     <mailto:bill.fischofer@linaro.org>>> wrote:
>     >>     > Signed-off-by: Bill Fischofer <bill.fischofer@linaro.org
>     <mailto:bill.fischofer@linaro.org>
>     >>     <mailto:bill.fischofer@linaro.org
>     <mailto:bill.fischofer@linaro.org>>>
>     >>     > ---
>     >>     > Note: This patch pre-reqs https://patches.linaro.org/42346/
>     >>     >
>     >>     > platform/linux-generic/include/odp_packet_internal.h | 6
>     ++++--
>     >>     >  1 file changed, 4 insertions(+), 2 deletions(-)
>     >>     >
>     >>     > diff --git
>     >>  a/platform/linux-generic/include/odp_packet_internal.h
>     >>  b/platform/linux-generic/include/odp_packet_internal.h
>     >>     > index 515c127..068f969 100644
>     >>     > --- a/platform/linux-generic/include/odp_packet_internal.h
>     >>     > +++ b/platform/linux-generic/include/odp_packet_internal.h
>     >>     > @@ -198,13 +198,15 @@ static inline void
>     >>     *packet_map(odp_packet_hdr_t *pkt_hdr,
>     >>     >  pkt_hdr->headroom + pkt_hdr->frame_len);
>     >>     >  }
>     >>     >
>     >>     > +#define ENABLE_OFFSET_UPDATES 0
>     >>     > +
>     >>     >  #define pull_offset(x, len) do { \
>     >>     > -       if (x != ODP_PACKET_OFFSET_INVALID) \
>     >>     > +       if (ENABLE_OFFSET_UPDATES && x !=
>     >>     ODP_PACKET_OFFSET_INVALID) \
>     >>     >                 x = x < len ? ODP_PACKET_OFFSET_INVALID :
>     x - len; \
>     >>     >         } while (0)
>     >>     >
>     >>     >  #define push_offset(x, len) do { \
>     >>     > -       if (x != ODP_PACKET_OFFSET_INVALID) \
>     >>     > +       if (ENABLE_OFFSET_UPDATES && x !=
>     >>     ODP_PACKET_OFFSET_INVALID) \
>     >>     >                 x += len; \
>     >>     >         } while (0)
>     >>     >
>     >>     > --
>     >>     > 1.8.3.2
>     >>     >
>     >>     >
>     >>     > _______________________________________________
>     >>     > lng-odp mailing list
>     >>     > lng-odp@lists.linaro.org
>     <mailto:lng-odp@lists.linaro.org> <mailto:lng-odp@lists.linaro.org
>     <mailto:lng-odp@lists.linaro.org>>
>     >>     > http://lists.linaro.org/mailman/listinfo/lng-odp
>     >>
>     >>
>     >>
>     >> _______________________________________________
>     >> lng-odp mailing list
>     >> lng-odp@lists.linaro.org <mailto:lng-odp@lists.linaro.org>
>     >> http://lists.linaro.org/mailman/listinfo/lng-odp
>     >
>     >
>     >
>     > _______________________________________________
>     > lng-odp mailing list
>     > lng-odp@lists.linaro.org <mailto:lng-odp@lists.linaro.org>
>     > http://lists.linaro.org/mailman/listinfo/lng-odp
>
>     _______________________________________________
>     lng-odp mailing list
>     lng-odp@lists.linaro.org <mailto:lng-odp@lists.linaro.org>
>     http://lists.linaro.org/mailman/listinfo/lng-odp
>
diff mbox

Patch

diff --git a/platform/linux-generic/include/odp_packet_internal.h b/platform/linux-generic/include/odp_packet_internal.h
index 515c127..068f969 100644
--- a/platform/linux-generic/include/odp_packet_internal.h
+++ b/platform/linux-generic/include/odp_packet_internal.h
@@ -198,13 +198,15 @@  static inline void *packet_map(odp_packet_hdr_t *pkt_hdr,
 			  pkt_hdr->headroom + pkt_hdr->frame_len);
 }
 
+#define ENABLE_OFFSET_UPDATES 0
+
 #define pull_offset(x, len) do { \
-	if (x != ODP_PACKET_OFFSET_INVALID) \
+	if (ENABLE_OFFSET_UPDATES && x != ODP_PACKET_OFFSET_INVALID) \
 		x = x < len ? ODP_PACKET_OFFSET_INVALID : x - len; \
 	} while (0)
 
 #define push_offset(x, len) do { \
-	if (x != ODP_PACKET_OFFSET_INVALID) \
+	if (ENABLE_OFFSET_UPDATES && x != ODP_PACKET_OFFSET_INVALID) \
 		x += len; \
 	} while (0)