linux-can.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Marc Kleine-Budde <mkl@pengutronix.de>
To: Oliver Hartkopp <socketcan@hartkopp.net>
Cc: linux-can@vger.kernel.org, mailhol.vincent@wanadoo.fr
Subject: Re: [PATCH net-next v2] can: gw: support modification of Classical CAN DLCs
Date: Thu, 19 Nov 2020 10:12:33 +0100	[thread overview]
Message-ID: <20201119091233.p4rsay26gta6tb74@hardanger.blackshift.org> (raw)
In-Reply-To: <20201119084921.2621-1-socketcan@hartkopp.net>

[-- Attachment #1: Type: text/plain, Size: 1319 bytes --]

On Thu, Nov 19, 2020 at 09:49:21AM +0100, Oliver Hartkopp wrote:
> Add support for data length code modifications for Classical CAN.
> 
> The netlink configuration interface always allowed to pass any value
> that fits into a byte, therefore only the modification process had to be
> extended to handle the raw DLC represenation of Classical CAN frames.
> 
> When a DLC value from 0 .. F is provided for Classical CAN frame
> modifications the 'len' value is modified as-is with the exception that
> potentially existing 9 .. F DLC values in the len8_dlc element are moved
> to the 'len' element for the modification operation by mod_retrieve_ccdlc().
> 
> After the modification the Classical CAN frame DLC information is brought
> back into the correct format by mod_store_ccdlc() which is filling 'len'
> and 'len8_dlc' accordingly.
> 
> Signed-off-by: Oliver Hartkopp <socketcan@hartkopp.net>
> 
> ---
> v2: remove unnecessary mod_retrieve_ccdlc() for 'set' modification

Added to linux-can-next/testing.

Thanks,
Marc

-- 
Pengutronix e.K.                 | Marc Kleine-Budde           |
Embedded Linux                   | https://www.pengutronix.de  |
Vertretung West/Dortmund         | Phone: +49-231-2826-924     |
Amtsgericht Hildesheim, HRA 2686 | Fax:   +49-5121-206917-5555 |

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

      reply	other threads:[~2020-11-19  9:13 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-11-19  8:49 [PATCH net-next v2] can: gw: support modification of Classical CAN DLCs Oliver Hartkopp
2020-11-19  9:12 ` Marc Kleine-Budde [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20201119091233.p4rsay26gta6tb74@hardanger.blackshift.org \
    --to=mkl@pengutronix.de \
    --cc=linux-can@vger.kernel.org \
    --cc=mailhol.vincent@wanadoo.fr \
    --cc=socketcan@hartkopp.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).