linux-fsdevel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Mauro Carvalho Chehab <mchehab@s-opensource.com>
To: Linux Media Mailing List <linux-media@vger.kernel.org>,
	Jonathan Corbet <corbet@lwn.net>
Cc: Mauro Carvalho Chehab <mchehab@s-opensource.com>,
	Mauro Carvalho Chehab <mchehab@infradead.org>,
	Linux Doc Mailing List <linux-doc@vger.kernel.org>,
	Sakari Ailus <sakari.ailus@linux.intel.com>,
	Geunyoung Kim <nenggun.kim@samsung.com>,
	Philippe Ombredanne <pombredanne@nexb.com>,
	Laurent Pinchart <laurent.pinchart@ideasonboard.com>,
	Seung-Woo Kim <sw0312.kim@samsung.com>,
	Junghak Sung <jh1009.sung@samsung.com>,
	Kyungmin Park <kyungmin.park@samsung.com>,
	Satendra Singh Thakur <satendra.t@samsung.com>,
	linux-fsdevel@vger.kernel.org,
	devendra sharma <devendra.sharma9091@gmail.com>,
	Alexander Viro <viro@zeniv.linux.org.uk>,
	Pawel Osciak <pawel@osciak.com>,
	Marek Szyprowski <m.szyprowski@samsung.com>,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	Thomas Gleixner <tglx@linutronix.de>,
	Inki Dae <inki.dae@samsung.com>,
	Kate Stewart <kstewart@linuxfoundation.org>
Subject: [PATCH 00/11] dvb: add support for memory mapped I/O
Date: Thu, 21 Dec 2017 14:17:59 -0200	[thread overview]
Message-ID: <cover.1513872637.git.mchehab@s-opensource.com> (raw)

This patch series is based on a work made by Samsung in 2015 meant
to add memory-mapped I/O to the Linux media, in order to improve
performance. The preparation patches were merged on that time, but
we didn't have time to test and finish the final patch.

Fortunately, Satendra helped us doing such port. On my tests, even
on USB drivers, where we need to do DMA at URB buffers, the
performance gains seem considerable.

On the tests I did today, with perf stat, the gains were expressive:

	- the number of task clocks reduced by 3,5 times;
	- the number of context switches reduced by about 4,5 times;
	- the number of CPU cycles reduced by almost 3,5 times;
	- the number of executed instructions reduced almost 2 times;
	- the number of cache references reduced by almost 8 times;
	- the number of cache misses reduced more than 4,5 times.

The patches are at:
	https://git.linuxtv.org/mchehab/experimental.git/log/?h=dvb_mmap

An userspace test patchset is at:
	https://git.linuxtv.org/mchehab/experimental-v4l-utils.git/log/?h=dvb_mmap

More details about my tests can be found on my comments to the
original Satendra's patch:

	https://patchwork.linuxtv.org/patch/46101/

Mauro Carvalho Chehab (9):
  media: vb2-core: add pr_fmt() macro
  media: vb2-core: add a new warning about pending buffers
  media: dvb_vb2: fix a warning about streamoff logic
  media: move videobuf2 to drivers/media/common
  media: dvb uAPI docs: document demux mmap/munmap syscalls
  media: dvb uAPI docs: document mmap-related ioctls
  media: dvb-core: get rid of mmap reserved field
  fs: compat_ioctl: add new DVB demux ioctls
  media: dvb_vb2: add SPDX headers

Satendra Singh Thakur (2):
  media: vb2-core: Fix a bug about unnecessary calls to queue cancel and
    free
  media: videobuf2: Add new uAPI for DVB streaming I/O

 Documentation/media/uapi/dvb/dmx-expbuf.rst        |  88 +++++
 Documentation/media/uapi/dvb/dmx-mmap.rst          | 116 ++++++
 Documentation/media/uapi/dvb/dmx-munmap.rst        |  54 +++
 Documentation/media/uapi/dvb/dmx-qbuf.rst          |  83 ++++
 Documentation/media/uapi/dvb/dmx-querybuf.rst      |  63 +++
 Documentation/media/uapi/dvb/dmx-reqbufs.rst       |  74 ++++
 Documentation/media/uapi/dvb/dmx_fcalls.rst        |   6 +
 drivers/media/common/Kconfig                       |   1 +
 drivers/media/common/Makefile                      |   2 +-
 drivers/media/common/videobuf/Kconfig              |  31 ++
 drivers/media/common/videobuf/Makefile             |   7 +
 .../videobuf}/videobuf2-core.c                     |  38 +-
 .../videobuf}/videobuf2-dma-contig.c               |   0
 .../videobuf}/videobuf2-dma-sg.c                   |   0
 .../{v4l2-core => common/videobuf}/videobuf2-dvb.c |   0
 .../videobuf}/videobuf2-memops.c                   |   0
 .../videobuf}/videobuf2-v4l2.c                     |   0
 .../videobuf}/videobuf2-vmalloc.c                  |   0
 drivers/media/dvb-core/Makefile                    |   2 +-
 drivers/media/dvb-core/dmxdev.c                    | 196 ++++++++--
 drivers/media/dvb-core/dmxdev.h                    |   4 +
 drivers/media/dvb-core/dvb_vb2.c                   | 430 +++++++++++++++++++++
 drivers/media/dvb-core/dvb_vb2.h                   |  74 ++++
 drivers/media/v4l2-core/Kconfig                    |  32 --
 drivers/media/v4l2-core/Makefile                   |   7 -
 fs/compat_ioctl.c                                  |   5 +
 include/uapi/linux/dvb/dmx.h                       |  63 ++-
 27 files changed, 1290 insertions(+), 86 deletions(-)
 create mode 100644 Documentation/media/uapi/dvb/dmx-expbuf.rst
 create mode 100644 Documentation/media/uapi/dvb/dmx-mmap.rst
 create mode 100644 Documentation/media/uapi/dvb/dmx-munmap.rst
 create mode 100644 Documentation/media/uapi/dvb/dmx-qbuf.rst
 create mode 100644 Documentation/media/uapi/dvb/dmx-querybuf.rst
 create mode 100644 Documentation/media/uapi/dvb/dmx-reqbufs.rst
 create mode 100644 drivers/media/common/videobuf/Kconfig
 create mode 100644 drivers/media/common/videobuf/Makefile
 rename drivers/media/{v4l2-core => common/videobuf}/videobuf2-core.c (98%)
 rename drivers/media/{v4l2-core => common/videobuf}/videobuf2-dma-contig.c (100%)
 rename drivers/media/{v4l2-core => common/videobuf}/videobuf2-dma-sg.c (100%)
 rename drivers/media/{v4l2-core => common/videobuf}/videobuf2-dvb.c (100%)
 rename drivers/media/{v4l2-core => common/videobuf}/videobuf2-memops.c (100%)
 rename drivers/media/{v4l2-core => common/videobuf}/videobuf2-v4l2.c (100%)
 rename drivers/media/{v4l2-core => common/videobuf}/videobuf2-vmalloc.c (100%)
 create mode 100644 drivers/media/dvb-core/dvb_vb2.c
 create mode 100644 drivers/media/dvb-core/dvb_vb2.h

-- 
2.14.3

             reply	other threads:[~2017-12-21 16:18 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-12-21 16:17 Mauro Carvalho Chehab [this message]
2017-12-21 16:18 ` [PATCH 10/11] fs: compat_ioctl: add new DVB demux ioctls Mauro Carvalho Chehab

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=cover.1513872637.git.mchehab@s-opensource.com \
    --to=mchehab@s-opensource.com \
    --cc=corbet@lwn.net \
    --cc=devendra.sharma9091@gmail.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=inki.dae@samsung.com \
    --cc=jh1009.sung@samsung.com \
    --cc=kstewart@linuxfoundation.org \
    --cc=kyungmin.park@samsung.com \
    --cc=laurent.pinchart@ideasonboard.com \
    --cc=linux-doc@vger.kernel.org \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=linux-media@vger.kernel.org \
    --cc=m.szyprowski@samsung.com \
    --cc=mchehab@infradead.org \
    --cc=nenggun.kim@samsung.com \
    --cc=pawel@osciak.com \
    --cc=pombredanne@nexb.com \
    --cc=sakari.ailus@linux.intel.com \
    --cc=satendra.t@samsung.com \
    --cc=sw0312.kim@samsung.com \
    --cc=tglx@linutronix.de \
    --cc=viro@zeniv.linux.org.uk \
    /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).