linux.kernel - 26 new messages in 20 topics - digest
linux.kernel
http://groups.google.com/group/linux.kernel?hl=en
linux.kernel@googlegroups.com
Today's topics:
* mfd: Add realtek USB card reader driver - 1 messages, 1 author
http://groups.google.com/group/linux.kernel/t/3db9414f96e490f1?hl=en
* ASoC: fsl: Add VF610 simple audio card widgets driver. - 3 messages, 1
author
http://groups.google.com/group/linux.kernel/t/9500e51bfb11acd1?hl=en
* vfio: Use new interfaces for MSI/MSI-X enablement - 2 messages, 2 authors
http://groups.google.com/group/linux.kernel/t/6035bbf945f5ceba?hl=en
* am335x: IIO/ADC fixes if used together with TSC, v2 - 2 messages, 2 authors
http://groups.google.com/group/linux.kernel/t/5c8d3fdac514f8ca?hl=en
* linux-next: manual merge of the gpio tree with the xtensa tree - 1 messages,
1 author
http://groups.google.com/group/linux.kernel/t/0929f0d23e7a91c6?hl=en
* Add shrink_pagecache_parent - 1 messages, 1 author
http://groups.google.com/group/linux.kernel/t/2401a0998ac7a4a1?hl=en
* 9b17c62382: -36.6% regression on sparse file copy - 1 messages, 1 author
http://groups.google.com/group/linux.kernel/t/cc0d90f622c30bd0?hl=en
* ASoC: twl4030: Remove local reg cache - 1 messages, 1 author
http://groups.google.com/group/linux.kernel/t/1d99e5738a5daa80?hl=en
* vb2: Check if there are buffers before streamon - 1 messages, 1 author
http://groups.google.com/group/linux.kernel/t/257ee1585451b40f?hl=en
* perf, tools: Add --delay support to perf record - 1 messages, 1 author
http://groups.google.com/group/linux.kernel/t/1d551f7c3d8454db?hl=en
* drm fixes - 1 messages, 1 author
http://groups.google.com/group/linux.kernel/t/80c3a3221b90f458?hl=en
* mfd: pm8921: Migrate to irqdomains - 1 messages, 1 author
http://groups.google.com/group/linux.kernel/t/24e221cf4752aa9d?hl=en
* mm: show message when updating min_free_kbytes in thp - 1 messages, 1 author
http://groups.google.com/group/linux.kernel/t/6e7b9f828e3b2d2d?hl=en
* mm readahead: Fix the readahead fail in case of empty numa node - 1 messages,
1 author
http://groups.google.com/group/linux.kernel/t/b006617214684ecc?hl=en
* sched: CPU topology try - 3 messages, 2 authors
http://groups.google.com/group/linux.kernel/t/c41eda64a33b68cb?hl=en
* comedi: Humusoft MF634 and MF624 DAQ cards driver - 1 messages, 1 author
http://groups.google.com/group/linux.kernel/t/c0839f496c247b8c?hl=en
* itrace: Infrastructure for instruction flow tracing units - 1 messages, 1
author
http://groups.google.com/group/linux.kernel/t/88bbae6fed905a8a?hl=en
* ARM: tegra: rework fuse.c - 1 messages, 1 author
http://groups.google.com/group/linux.kernel/t/b1ad7acf3cb19f99?hl=en
* iommu/vt-d: mark internal functions as static - 1 messages, 1 author
http://groups.google.com/group/linux.kernel/t/779b56bb501a9e2e?hl=en
* dma: imx-sdma: Assign a default script number for ROM firmware cases - 1
messages, 1 author
http://groups.google.com/group/linux.kernel/t/036ea89c373e53bd?hl=en
==============================================================================
TOPIC: mfd: Add realtek USB card reader driver
http://groups.google.com/group/linux.kernel/t/3db9414f96e490f1?hl=en
==============================================================================
== 1 of 1 ==
Date: Wed, Jan 8 2014 12:00 am
From: Roger Tseng
Hi Dan,
>> +int rtsx_usb_ep0_write_register(struct rtsx_ucr *ucr, u16 addr,
>> + u8 mask, u8 data)
>> +{
>> + u16 value = 0, index = 0;
>> +
>> + value |= (u16)(3 & 0x03) << 14;
>> + value |= (u16)(addr & 0x3FFF);
>
>Don't do pointless things:
>
> value |= 0x03 << 14;
> value |= addr & 0x3FFF;
>
>> + value = ((value << 8) & 0xFF00) | ((value >> 8) & 0x00FF);
>
>This is an endian conversion? It is buggy. Use the kernel endian
>conversion functions cpu_to_le16().
This is not a conversion for endianess with respect to CPU but for command format of the device. It should always be performed regardless of platform.
In other words, it could be equivalent to:
value |= 0x03 << 6; // lower byte
value |= (addr & 0x3F00) >> 8; // lower byte
value |= (addr & 0xFF) << 8; //higher byte
We think the previous form is easier to read. Should we keep it or change to the later one?--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
==============================================================================
TOPIC: ASoC: fsl: Add VF610 simple audio card widgets driver.
http://groups.google.com/group/linux.kernel/t/9500e51bfb11acd1?hl=en
==============================================================================
== 1 of 3 ==
Date: Wed, Jan 8 2014 12:00 am
From: Xiubo Li
This is the SGTL5000 codec based off-CODEC widgets supports.
Signed-off-by: Xiubo Li <Li.Xiubo@freescale.com>
---
sound/soc/fsl/Kconfig | 25 ++++++++++++++++++
sound/soc/fsl/Makefile | 3 +++
sound/soc/fsl/snd-soc-simple-card-vf610.c | 44 +++++++++++++++++++++++++++++++
3 files changed, 72 insertions(+)
create mode 100644 sound/soc/fsl/snd-soc-simple-card-vf610.c
diff --git a/sound/soc/fsl/Kconfig b/sound/soc/fsl/Kconfig
index 514c275..fc25d8a 100644
--- a/sound/soc/fsl/Kconfig
+++ b/sound/soc/fsl/Kconfig
@@ -216,3 +216,28 @@ config SND_SOC_IMX_MC13783
select SND_SOC_IMX_PCM_DMA
endif # SND_IMX_SOC
+
+menuconfig SND_VF610_SOC
+ tristate "SoC Audio for Freescale VF610 CPUs"
+ select DMA_ENGINE
+ help
+ Say Y or M if you want to add support for codecs attached to
+ the VF610 CPUs.
+
+ This will enable Freeacale SAI and SGTL5000 codec, and an extra
+ TWR-AUDIO-SGTL sub-board is needed for SGTL5000.
+
+if SND_VF610_SOC
+
+config SND_SOC_VF610_SGTL5000
+ tristate "SoC Audio support for VF610 boards with SGTL5000"
+ depends on OF && I2C
+ select SND_SOC_FSL_SAI
+ select SND_SOC_SGTL5000
+ select SND_SIMPLE_CARD
+ help
+ Say Y if you want to add support for SoC audio on an VF610 board with
+ a SGTL5000 codec and a SAI.
+
+
+endif #SND_VF610_SOC
diff --git a/sound/soc/fsl/Makefile b/sound/soc/fsl/Makefile
index aaccbee..19690c5 100644
--- a/sound/soc/fsl/Makefile
+++ b/sound/soc/fsl/Makefile
@@ -58,3 +58,6 @@ obj-$(CONFIG_SND_SOC_IMX_SGTL5000) += snd-soc-imx-sgtl5000.o
obj-$(CONFIG_SND_SOC_IMX_WM8962) += snd-soc-imx-wm8962.o
obj-$(CONFIG_SND_SOC_IMX_SPDIF) += snd-soc-imx-spdif.o
obj-$(CONFIG_SND_SOC_IMX_MC13783) += snd-soc-imx-mc13783.o
+
+# Simple audio card widgets Support
+obj-$(CONFIG_SND_SOC_VF610_SGTL5000) += snd-soc-simple-card-vf610.o
diff --git a/sound/soc/fsl/snd-soc-simple-card-vf610.c b/sound/soc/fsl/snd-soc-simple-card-vf610.c
new file mode 100644
index 0000000..692561c
--- /dev/null
+++ b/sound/soc/fsl/snd-soc-simple-card-vf610.c
@@ -0,0 +1,44 @@
+/*
+ * ASoC VF610 SGTL5000 off-CODEC widgets support
+ *
+ * Copyright 2013 Freescale Semiconductor, Inc.
+ * Xiubo Li <Li.Xiubo@freescale.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation.
+ */
+#include <linux/module.h>
+#include <sound/simple_card.h>
+#include <sound/soc-dapm.h>
+
+static const struct snd_soc_dapm_widget vf610_sgtl5000_dapm_widgets[] = {
+ SND_SOC_DAPM_MIC("Mic Jack", NULL),
+ SND_SOC_DAPM_LINE("Line In Jack", NULL),
+ SND_SOC_DAPM_HP("Headphone Jack", NULL),
+ SND_SOC_DAPM_SPK("Line Out Jack", NULL),
+ SND_SOC_DAPM_SPK("Ext Spk", NULL),
+};
+
+struct asoc_simple_card_widgets vf610_sgtl5000_widgets = {
+ .name = "vf610-sgtl5000",
+ .widgets = vf610_sgtl5000_dapm_widgets,
+ .widgets_cnt = ARRAY_SIZE(vf610_sgtl5000_dapm_widgets),
+};
+
+static int __init __vf610_sgtl5000_widgets_init(void)
+{
+ return asoc_simple_card_widgets_register(&vf610_sgtl5000_widgets);
+}
+module_init(__vf610_sgtl5000_widgets_init);
+
+static void __exit __vf610_sgtl5000_widgets_exit(void)
+{
+ asoc_simple_card_widgets_unregister(&vf610_sgtl5000_widgets);
+}
+module_exit(__vf610_sgtl5000_widgets_exit);
+
+MODULE_LICENSE("GPL");
+MODULE_ALIAS("platform:vf610-simple-card-widgets");
+MODULE_DESCRIPTION("ASoC Simple Sound Card Widgets");
+MODULE_AUTHOR("Xiubo Li <Li.Xiubo@freescale.com>");
--
1.8.4
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
== 2 of 3 ==
Date: Wed, Jan 8 2014 12:00 am
From: Xiubo Li
For many audio cards there need to add some off-CODEC widgets, and this
is hard to be supported by dts only, because maybe some widgets need one
or more call backs, such as wevent.
Signed-off-by: Xiubo Li <Li.Xiubo@freescale.com>
---
.../devicetree/bindings/sound/simple-card.txt | 1 +
include/sound/simple_card.h | 14 ++++
sound/soc/generic/Makefile | 3 +-
sound/soc/generic/simple-card-widgets.c | 79 ++++++++++++++++++++++
4 files changed, 96 insertions(+), 1 deletion(-)
create mode 100644 sound/soc/generic/simple-card-widgets.c
diff --git a/Documentation/devicetree/bindings/sound/simple-card.txt b/Documentation/devicetree/bindings/sound/simple-card.txt
index e9e20ec..e626302 100644
--- a/Documentation/devicetree/bindings/sound/simple-card.txt
+++ b/Documentation/devicetree/bindings/sound/simple-card.txt
@@ -15,6 +15,7 @@ Optional properties:
Each entry is a pair of strings, the first being the
connection's sink, the second being the connection's
source.
+- simple-sudio-card,widgets : The name of the audio card off-CODEC widgets.
Required subnodes:
diff --git a/include/sound/simple_card.h b/include/sound/simple_card.h
index 6c74527..75574f8 100644
--- a/include/sound/simple_card.h
+++ b/include/sound/simple_card.h
@@ -12,8 +12,16 @@
#ifndef __SIMPLE_CARD_H
#define __SIMPLE_CARD_H
+#include <linux/of.h>
#include <sound/soc.h>
+struct asoc_simple_card_widgets {
+ const char *name;
+ struct list_head list;
+ const struct snd_soc_dapm_widget *widgets;
+ unsigned int widgets_cnt;
+};
+
struct asoc_simple_dai {
const char *name;
unsigned int fmt;
@@ -35,4 +43,10 @@ struct asoc_simple_card_info {
struct snd_soc_card snd_card;
};
+struct asoc_simple_card_widgets *
+asoc_simple_card_get_widgets(struct device_node *);
+int asoc_simple_card_widgets_register(struct asoc_simple_card_widgets *);
+void
+asoc_simple_card_widgets_unregister(struct asoc_simple_card_widgets *);
+
0 Comments:
Post a Comment
Subscribe to Post Comments [Atom]
<< Home