linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v3 0/6] can: c_can: add support to 64 message objects
@ 2021-02-28 10:38 Dario Binacchi
  2021-02-28 10:38 ` [PATCH v3 1/6] can: c_can: remove unused code Dario Binacchi
                   ` (5 more replies)
  0 siblings, 6 replies; 23+ messages in thread
From: Dario Binacchi @ 2021-02-28 10:38 UTC (permalink / raw)
  To: linux-kernel
  Cc: Federico Vaga, Alexander Stein, Dario Binacchi, David S. Miller,
	Jakub Kicinski, Marc Kleine-Budde, Oliver Hartkopp,
	Vincent Mailhol, Wolfgang Grandegger, YueHaibing, Zhang Qilong,
	linux-can, netdev


The D_CAN controller supports up to 128 messages. Until now the driver
only managed 32 messages although Sitara processors and DRA7 SOC can
handle 64.

The series was tested on a beaglebone board.

Note:
I have not changed the type of tx_field (belonging to the c_can_priv
structure) to atomic64_t because I think the atomic_t type has size
of at least 32 bits on x86 and arm, which is enough to handle 64
messages.
http://marc.info/?l=linux-can&m=139746476821294&w=2 reports the results
of tests performed just on x86 and arm architectures.

Changes in v3:
- Use unsigned int instead of int as type of the msg_obj_* fields
  in the c_can_priv structure.
- Replace (u64)1 with 1UL in msg_obj_rx_mask setting.
- Use unsigned int instead of int as type of the msg_obj_num field
  in c_can_driver_data and c_can_pci_data structures.

Changes in v2:
- Fix compiling error reported by kernel test robot.
- Add Reported-by tag.
- Pass larger size to alloc_candev() routine to avoid an additional
  memory allocation/deallocation.
- Add message objects number to PCI driver data.

Dario Binacchi (6):
  can: c_can: remove unused code
  can: c_can: fix indentation
  can: c_can: fix control interface used by c_can_do_tx
  can: c_can: use 32-bit write to set arbitration register
  can: c_can: prepare to up the message objects number
  can: c_can: add support to 64 message objects

 drivers/net/can/c_can/c_can.c          | 77 +++++++++++++++-----------
 drivers/net/can/c_can/c_can.h          | 32 +++++------
 drivers/net/can/c_can/c_can_pci.c      |  6 +-
 drivers/net/can/c_can/c_can_platform.c |  6 +-
 4 files changed, 68 insertions(+), 53 deletions(-)

-- 
2.17.1


^ permalink raw reply	[flat|nested] 23+ messages in thread

end of thread, other threads:[~2021-03-03 15:28 UTC | newest]

Thread overview: 23+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-02-28 10:38 [PATCH v3 0/6] can: c_can: add support to 64 message objects Dario Binacchi
2021-02-28 10:38 ` [PATCH v3 1/6] can: c_can: remove unused code Dario Binacchi
2021-02-28 10:38 ` [PATCH v3 2/6] can: c_can: fix indentation Dario Binacchi
2021-02-28 10:38 ` [PATCH v3 3/6] can: c_can: fix control interface used by c_can_do_tx Dario Binacchi
2021-03-02 18:44   ` Kurt Van Dijck
2021-03-03  7:22     ` Dario Binacchi
2021-02-28 10:38 ` [PATCH v3 4/6] can: c_can: use 32-bit write to set arbitration register Dario Binacchi
2021-02-28 10:38 ` [PATCH v3 5/6] can: c_can: prepare to up the message objects number Dario Binacchi
2021-03-01 11:38   ` Marc Kleine-Budde
2021-03-01 13:08     ` Marc Kleine-Budde
2021-03-01 16:54       ` Marc Kleine-Budde
2021-03-01 17:24       ` Dario Binacchi
2021-03-01 19:46         ` Marc Kleine-Budde
2021-03-01 17:21     ` Dario Binacchi
2021-03-01 19:45       ` Marc Kleine-Budde
2021-03-02 10:50         ` Dario Binacchi
2021-03-02 10:56           ` Marc Kleine-Budde
2021-03-02 18:49   ` Kurt Van Dijck
2021-03-03  8:23     ` Dario Binacchi
2021-03-03  9:00       ` Marc Kleine-Budde
2021-03-03 10:31         ` Dario Binacchi
2021-03-03 10:36           ` Marc Kleine-Budde
2021-02-28 10:38 ` [PATCH v3 6/6] can: c_can: add support to 64 message objects Dario Binacchi

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).