summaryrefslogtreecommitdiffstats
path: root/drivers/hsi/clients/cmt_speech.c
AgeCommit message (Collapse)Author
2015-09-10mm: mark most vm_operations_struct constKirill A. Shutemov
With two exceptions (drm/qxl and drm/radeon) all vm_operations_struct structs should be constant. Signed-off-by: Kirill A. Shutemov <kirill.shutemov@linux.intel.com> Reviewed-by: Oleg Nesterov <oleg@redhat.com> Cc: "H. Peter Anvin" <hpa@zytor.com> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Dave Hansen <dave.hansen@linux.intel.com> Cc: Ingo Molnar <mingo@elte.hu> Cc: Minchan Kim <minchan@kernel.org> Cc: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2015-06-23HSI: cmt_speech: fix timestamp interfaceSebastian Reichel
The user interface for timestamps in the new cmt_speech driver is broken in multiple ways: - The layout is incompatible between 32-bit and 64-bit user space, because of the size differences in 'struct timespec'. This means that the driver can not work when used with 32-bit user space on a 64-bit kernel. - As there are plans to change 32-bit user space to use a 64-bit time_t type in the future, it will also be incompatible with new 32-bit user space. - It is using ktime_get_ts under it's deprecated alias (do_posix_clock_monotonic_gettime). To keep support for the user space tools written for this driver (which have lived many years out-of-tree), the interface has been hardened to unsigned 32-bit values. Reported-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Sebastian Reichel <sre@kernel.org>
2015-04-05HSI: cmt_speech: fix error return codeJulia Lawall
Return a negative error code on failure. A simplified version of the semantic match that finds this problem is as follows: (http://coccinelle.lip6.fr/) // <smpl> @@ identifier ret; expression e1,e2; @@ ( if (\(ret < 0\|ret != 0\)) { ... return ret; } | ret = 0 ) ... when != ret = e1 when != &ret *if(...) { ... when != ret = e2 when forall return ret; } // </smpl> Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr> Signed-off-by: Sebastian Reichel <sre@kernel.org>
2015-03-31HSI: cmt_speech: Add cmt-speech driverKai Vehmanen
Introduces the cmt-speech driver, which implements a character device interface for transferring speech data frames over HSI/SSI. The driver is used to exchange voice/speech data between the Nokia N900/N950/N9's modem and its cpu. Signed-off-by: Kai Vehmanen <kai.vehmanen@nokia.com> Signed-off-by: Carlos Chinea <carlos.chinea@nokia.com> Signed-off-by: Joni Lapilainen <joni.lapilainen@gmail.com> Since the original driver has been written for 2.6.28 some build fixes and general cleanups have been added by me: * fix build for 4.0 kernel * replace GFP_ATOMIC with GFP_KERNEL in cs_alloc_cmds() * add sanity check for CS_SET_WAKELINE ioctl * cleanup driver initialisation * rename driver to cmt-speech to be consistent with ssi-protocol driver * move cs-protocol.h to include/uapi/linux/hsi, since it describes a userspace API * replace hardcoded channels numbers with values provided via the HSI framework (e.g. coming from DT) Acked-by: Aaro Koskinen <aaro.koskinen@iki.fi> Tested-by: Pavel Machek <pavel@ucw.cz> Signed-off-by: Sebastian Reichel <sre@kernel.org>