diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2017-12-05 12:57:34 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2017-12-05 12:57:34 -0500 |
commit | 73996933b53ff396d63a7fccd8e824758634dc19 (patch) | |
tree | bd950af66319d6b2f28e23889ee38f580771c6af | |
parent | 84dda2965d2a8d319e5f47cef46697cf9153f272 (diff) | |
parent | e168e9845d956e6d0c057f9ecd28782a1ab4a08a (diff) |
Merge tag 'staging-4.15-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging
Pull staging and iio driver fixes from Greg KH:
"Here are a number of small staging and iio driver fixes for reported
issues for 4.15-rc3. Nothing major here, the majority is IIO issues,
like normal, but there are also some small bugfixes for a few staging
drivers as well.
Full details are in the shortlog.
All of these have been in linux-next for a while with no reported
issues"
* tag 'staging-4.15-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging:
iio: stm32: fix adc/trigger link error
iio: health: max30102: Temperature should be in milli Celsius
iio: fix kernel-doc build errors
iio: adc: meson-saradc: Meson8 and Meson8b do not have REG11 and REG13
iio: adc: meson-saradc: initialize the bandgap correctly on older SoCs
iio: adc: meson-saradc: fix the bit_idx of the adc_en clock
iio: proximity: sx9500: Assign interrupt from GpioIo()
iio: adc: cpcap: fix incorrect validation
staging: octeon-usb: use __delay() instead of cvmx_wait()
staging: rtl8188eu: Fix incorrect response to SIOCGIWESSID
staging: ccree: fix leak of import() after init()
staging: comedi: ni_atmio: fix license warning.
-rw-r--r-- | drivers/iio/adc/cpcap-adc.c | 2 | ||||
-rw-r--r-- | drivers/iio/adc/meson_saradc.c | 52 | ||||
-rw-r--r-- | drivers/iio/health/max30102.c | 2 | ||||
-rw-r--r-- | drivers/iio/industrialio-core.c | 4 | ||||
-rw-r--r-- | drivers/iio/proximity/sx9500.c | 9 | ||||
-rw-r--r-- | drivers/staging/ccree/ssi_hash.c | 9 | ||||
-rw-r--r-- | drivers/staging/comedi/drivers/ni_atmio.c | 5 | ||||
-rw-r--r-- | drivers/staging/octeon-usb/octeon-hcd.c | 6 | ||||
-rw-r--r-- | drivers/staging/rtl8188eu/os_dep/ioctl_linux.c | 14 | ||||
-rw-r--r-- | include/linux/iio/timer/stm32-lptim-trigger.h | 5 |
10 files changed, 77 insertions, 31 deletions
diff --git a/drivers/iio/adc/cpcap-adc.c b/drivers/iio/adc/cpcap-adc.c index 3576ec73ec23..9ad60421d360 100644 --- a/drivers/iio/adc/cpcap-adc.c +++ b/drivers/iio/adc/cpcap-adc.c | |||
@@ -1011,7 +1011,7 @@ static int cpcap_adc_probe(struct platform_device *pdev) | |||
1011 | platform_set_drvdata(pdev, indio_dev); | 1011 | platform_set_drvdata(pdev, indio_dev); |
1012 | 1012 | ||
1013 | ddata->irq = platform_get_irq_byname(pdev, "adcdone"); | 1013 | ddata->irq = platform_get_irq_byname(pdev, "adcdone"); |
1014 | if (!ddata->irq) | 1014 | if (ddata->irq < 0) |
1015 | return -ENODEV; | 1015 | return -ENODEV; |
1016 | 1016 | ||
1017 | error = devm_request_threaded_irq(&pdev->dev, ddata->irq, NULL, | 1017 | error = devm_request_threaded_irq(&pdev->dev, ddata->irq, NULL, |
diff --git a/drivers/iio/adc/meson_saradc.c b/drivers/iio/adc/meson_saradc.c index 9c6932ffc0af..36047147ce7c 100644 --- a/drivers/iio/adc/meson_saradc.c +++ b/drivers/iio/adc/meson_saradc.c | |||
@@ -221,8 +221,10 @@ enum meson_sar_adc_chan7_mux_sel { | |||
221 | 221 | ||
222 | struct meson_sar_adc_data { | 222 | struct meson_sar_adc_data { |
223 | bool has_bl30_integration; | 223 | bool has_bl30_integration; |
224 | u32 bandgap_reg; | ||
224 | unsigned int resolution; | 225 | unsigned int resolution; |
225 | const char *name; | 226 | const char *name; |
227 | const struct regmap_config *regmap_config; | ||
226 | }; | 228 | }; |
227 | 229 | ||
228 | struct meson_sar_adc_priv { | 230 | struct meson_sar_adc_priv { |
@@ -242,13 +244,20 @@ struct meson_sar_adc_priv { | |||
242 | int calibscale; | 244 | int calibscale; |
243 | }; | 245 | }; |
244 | 246 | ||
245 | static const struct regmap_config meson_sar_adc_regmap_config = { | 247 | static const struct regmap_config meson_sar_adc_regmap_config_gxbb = { |
246 | .reg_bits = 8, | 248 | .reg_bits = 8, |
247 | .val_bits = 32, | 249 | .val_bits = 32, |
248 | .reg_stride = 4, | 250 | .reg_stride = 4, |
249 | .max_register = MESON_SAR_ADC_REG13, | 251 | .max_register = MESON_SAR_ADC_REG13, |
250 | }; | 252 | }; |
251 | 253 | ||
254 | static const struct regmap_config meson_sar_adc_regmap_config_meson8 = { | ||
255 | .reg_bits = 8, | ||
256 | .val_bits = 32, | ||
257 | .reg_stride = 4, | ||
258 | .max_register = MESON_SAR_ADC_DELTA_10, | ||
259 | }; | ||
260 | |||
252 | static unsigned int meson_sar_adc_get_fifo_count(struct iio_dev *indio_dev) | 261 | static unsigned int meson_sar_adc_get_fifo_count(struct iio_dev *indio_dev) |
253 | { | 262 | { |
254 | struct meson_sar_adc_priv *priv = iio_priv(indio_dev); | 263 | struct meson_sar_adc_priv *priv = iio_priv(indio_dev); |
@@ -600,7 +609,7 @@ static int meson_sar_adc_clk_init(struct iio_dev *indio_dev, | |||
600 | init.num_parents = 1; | 609 | init.num_parents = 1; |
601 | 610 | ||
602 | priv->clk_gate.reg = base + MESON_SAR_ADC_REG3; | 611 | priv->clk_gate.reg = base + MESON_SAR_ADC_REG3; |
603 | priv->clk_gate.bit_idx = fls(MESON_SAR_ADC_REG3_CLK_EN); | 612 | priv->clk_gate.bit_idx = __ffs(MESON_SAR_ADC_REG3_CLK_EN); |
604 | priv->clk_gate.hw.init = &init; | 613 | priv->clk_gate.hw.init = &init; |
605 | 614 | ||
606 | priv->adc_clk = devm_clk_register(&indio_dev->dev, &priv->clk_gate.hw); | 615 | priv->adc_clk = devm_clk_register(&indio_dev->dev, &priv->clk_gate.hw); |
@@ -685,6 +694,20 @@ static int meson_sar_adc_init(struct iio_dev *indio_dev) | |||
685 | return 0; | 694 | return 0; |
686 | } | 695 | } |
687 | 696 | ||
697 | static void meson_sar_adc_set_bandgap(struct iio_dev *indio_dev, bool on_off) | ||
698 | { | ||
699 | struct meson_sar_adc_priv *priv = iio_priv(indio_dev); | ||
700 | u32 enable_mask; | ||
701 | |||
702 | if (priv->data->bandgap_reg == MESON_SAR_ADC_REG11) | ||
703 | enable_mask = MESON_SAR_ADC_REG11_BANDGAP_EN; | ||
704 | else | ||
705 | enable_mask = MESON_SAR_ADC_DELTA_10_TS_VBG_EN; | ||
706 | |||
707 | regmap_update_bits(priv->regmap, priv->data->bandgap_reg, enable_mask, | ||
708 | on_off ? enable_mask : 0); | ||
709 | } | ||
710 | |||
688 | static int meson_sar_adc_hw_enable(struct iio_dev *indio_dev) | 711 | static int meson_sar_adc_hw_enable(struct iio_dev *indio_dev) |
689 | { | 712 | { |
690 | struct meson_sar_adc_priv *priv = iio_priv(indio_dev); | 713 | struct meson_sar_adc_priv *priv = iio_priv(indio_dev); |
@@ -717,9 +740,9 @@ static int meson_sar_adc_hw_enable(struct iio_dev *indio_dev) | |||
717 | regval = FIELD_PREP(MESON_SAR_ADC_REG0_FIFO_CNT_IRQ_MASK, 1); | 740 | regval = FIELD_PREP(MESON_SAR_ADC_REG0_FIFO_CNT_IRQ_MASK, 1); |
718 | regmap_update_bits(priv->regmap, MESON_SAR_ADC_REG0, | 741 | regmap_update_bits(priv->regmap, MESON_SAR_ADC_REG0, |
719 | MESON_SAR_ADC_REG0_FIFO_CNT_IRQ_MASK, regval); | 742 | MESON_SAR_ADC_REG0_FIFO_CNT_IRQ_MASK, regval); |
720 | regmap_update_bits(priv->regmap, MESON_SAR_ADC_REG11, | 743 | |
721 | MESON_SAR_ADC_REG11_BANDGAP_EN, | 744 | meson_sar_adc_set_bandgap(indio_dev, true); |
722 | MESON_SAR_ADC_REG11_BANDGAP_EN); | 745 | |
723 | regmap_update_bits(priv->regmap, MESON_SAR_ADC_REG3, | 746 | regmap_update_bits(priv->regmap, MESON_SAR_ADC_REG3, |
724 | MESON_SAR_ADC_REG3_ADC_EN, | 747 | MESON_SAR_ADC_REG3_ADC_EN, |
725 | MESON_SAR_ADC_REG3_ADC_EN); | 748 | MESON_SAR_ADC_REG3_ADC_EN); |
@@ -739,8 +762,7 @@ static int meson_sar_adc_hw_enable(struct iio_dev *indio_dev) | |||
739 | err_adc_clk: | 762 | err_adc_clk: |
740 | regmap_update_bits(priv->regmap, MESON_SAR_ADC_REG3, | 763 | regmap_update_bits(priv->regmap, MESON_SAR_ADC_REG3, |
741 | MESON_SAR_ADC_REG3_ADC_EN, 0); | 764 | MESON_SAR_ADC_REG3_ADC_EN, 0); |
742 | regmap_update_bits(priv->regmap, MESON_SAR_ADC_REG11, | 765 | meson_sar_adc_set_bandgap(indio_dev, false); |
743 | MESON_SAR_ADC_REG11_BANDGAP_EN, 0); | ||
744 | clk_disable_unprepare(priv->sana_clk); | 766 | clk_disable_unprepare(priv->sana_clk); |
745 | err_sana_clk: | 767 | err_sana_clk: |
746 | clk_disable_unprepare(priv->core_clk); | 768 | clk_disable_unprepare(priv->core_clk); |
@@ -765,8 +787,8 @@ static int meson_sar_adc_hw_disable(struct iio_dev *indio_dev) | |||
765 | 787 | ||
766 | regmap_update_bits(priv->regmap, MESON_SAR_ADC_REG3, | 788 | regmap_update_bits(priv->regmap, MESON_SAR_ADC_REG3, |
767 | MESON_SAR_ADC_REG3_ADC_EN, 0); | 789 | MESON_SAR_ADC_REG3_ADC_EN, 0); |
768 | regmap_update_bits(priv->regmap, MESON_SAR_ADC_REG11, | 790 | |
769 | MESON_SAR_ADC_REG11_BANDGAP_EN, 0); | 791 | meson_sar_adc_set_bandgap(indio_dev, false); |
770 | 792 | ||
771 | clk_disable_unprepare(priv->sana_clk); | 793 | clk_disable_unprepare(priv->sana_clk); |
772 | clk_disable_unprepare(priv->core_clk); | 794 | clk_disable_unprepare(priv->core_clk); |
@@ -844,30 +866,40 @@ static const struct iio_info meson_sar_adc_iio_info = { | |||
844 | 866 | ||
845 | static const struct meson_sar_adc_data meson_sar_adc_meson8_data = { | 867 | static const struct meson_sar_adc_data meson_sar_adc_meson8_data = { |
846 | .has_bl30_integration = false, | 868 | .has_bl30_integration = false, |
869 | .bandgap_reg = MESON_SAR_ADC_DELTA_10, | ||
870 | .regmap_config = &meson_sar_adc_regmap_config_meson8, | ||
847 | .resolution = 10, | 871 | .resolution = 10, |
848 | .name = "meson-meson8-saradc", | 872 | .name = "meson-meson8-saradc", |
849 | }; | 873 | }; |
850 | 874 | ||
851 | static const struct meson_sar_adc_data meson_sar_adc_meson8b_data = { | 875 | static const struct meson_sar_adc_data meson_sar_adc_meson8b_data = { |
852 | .has_bl30_integration = false, | 876 | .has_bl30_integration = false, |
877 | .bandgap_reg = MESON_SAR_ADC_DELTA_10, | ||
878 | .regmap_config = &meson_sar_adc_regmap_config_meson8, | ||
853 | .resolution = 10, | 879 | .resolution = 10, |
854 | .name = "meson-meson8b-saradc", | 880 | .name = "meson-meson8b-saradc", |
855 | }; | 881 | }; |
856 | 882 | ||
857 | static const struct meson_sar_adc_data meson_sar_adc_gxbb_data = { | 883 | static const struct meson_sar_adc_data meson_sar_adc_gxbb_data = { |
858 | .has_bl30_integration = true, | 884 | .has_bl30_integration = true, |
885 | .bandgap_reg = MESON_SAR_ADC_REG11, | ||
886 | .regmap_config = &meson_sar_adc_regmap_config_gxbb, | ||
859 | .resolution = 10, | 887 | .resolution = 10, |
860 | .name = "meson-gxbb-saradc", | 888 | .name = "meson-gxbb-saradc", |
861 | }; | 889 | }; |
862 | 890 | ||
863 | static const struct meson_sar_adc_data meson_sar_adc_gxl_data = { | 891 | static const struct meson_sar_adc_data meson_sar_adc_gxl_data = { |
864 | .has_bl30_integration = true, | 892 | .has_bl30_integration = true, |
893 | .bandgap_reg = MESON_SAR_ADC_REG11, | ||
894 | .regmap_config = &meson_sar_adc_regmap_config_gxbb, | ||
865 | .resolution = 12, | 895 | .resolution = 12, |
866 | .name = "meson-gxl-saradc", | 896 | .name = "meson-gxl-saradc", |
867 | }; | 897 | }; |
868 | 898 | ||
869 | static const struct meson_sar_adc_data meson_sar_adc_gxm_data = { | 899 | static const struct meson_sar_adc_data meson_sar_adc_gxm_data = { |
870 | .has_bl30_integration = true, | 900 | .has_bl30_integration = true, |
901 | .bandgap_reg = MESON_SAR_ADC_REG11, | ||
902 | .regmap_config = &meson_sar_adc_regmap_config_gxbb, | ||
871 | .resolution = 12, | 903 | .resolution = 12, |
872 | .name = "meson-gxm-saradc", | 904 | .name = "meson-gxm-saradc", |
873 | }; | 905 | }; |
@@ -945,7 +977,7 @@ static int meson_sar_adc_probe(struct platform_device *pdev) | |||
945 | return ret; | 977 | return ret; |
946 | 978 | ||
947 | priv->regmap = devm_regmap_init_mmio(&pdev->dev, base, | 979 | priv->regmap = devm_regmap_init_mmio(&pdev->dev, base, |
948 | &meson_sar_adc_regmap_config); | 980 | priv->data->regmap_config); |
949 | if (IS_ERR(priv->regmap)) | 981 | if (IS_ERR(priv->regmap)) |
950 | return PTR_ERR(priv->regmap); | 982 | return PTR_ERR(priv->regmap); |
951 | 983 | ||
diff --git a/drivers/iio/health/max30102.c b/drivers/iio/health/max30102.c index 203ffb9cad6a..147a8c14235f 100644 --- a/drivers/iio/health/max30102.c +++ b/drivers/iio/health/max30102.c | |||
@@ -371,7 +371,7 @@ static int max30102_read_raw(struct iio_dev *indio_dev, | |||
371 | mutex_unlock(&indio_dev->mlock); | 371 | mutex_unlock(&indio_dev->mlock); |
372 | break; | 372 | break; |
373 | case IIO_CHAN_INFO_SCALE: | 373 | case IIO_CHAN_INFO_SCALE: |
374 | *val = 1; /* 0.0625 */ | 374 | *val = 1000; /* 62.5 */ |
375 | *val2 = 16; | 375 | *val2 = 16; |
376 | ret = IIO_VAL_FRACTIONAL; | 376 | ret = IIO_VAL_FRACTIONAL; |
377 | break; | 377 | break; |
diff --git a/drivers/iio/industrialio-core.c b/drivers/iio/industrialio-core.c index 9c4cfd19b739..2f0998ebeed2 100644 --- a/drivers/iio/industrialio-core.c +++ b/drivers/iio/industrialio-core.c | |||
@@ -631,7 +631,7 @@ static ssize_t __iio_format_value(char *buf, size_t len, unsigned int type, | |||
631 | * iio_format_value() - Formats a IIO value into its string representation | 631 | * iio_format_value() - Formats a IIO value into its string representation |
632 | * @buf: The buffer to which the formatted value gets written | 632 | * @buf: The buffer to which the formatted value gets written |
633 | * which is assumed to be big enough (i.e. PAGE_SIZE). | 633 | * which is assumed to be big enough (i.e. PAGE_SIZE). |
634 | * @type: One of the IIO_VAL_... constants. This decides how the val | 634 | * @type: One of the IIO_VAL_* constants. This decides how the val |
635 | * and val2 parameters are formatted. | 635 | * and val2 parameters are formatted. |
636 | * @size: Number of IIO value entries contained in vals | 636 | * @size: Number of IIO value entries contained in vals |
637 | * @vals: Pointer to the values, exact meaning depends on the | 637 | * @vals: Pointer to the values, exact meaning depends on the |
@@ -639,7 +639,7 @@ static ssize_t __iio_format_value(char *buf, size_t len, unsigned int type, | |||
639 | * | 639 | * |
640 | * Return: 0 by default, a negative number on failure or the | 640 | * Return: 0 by default, a negative number on failure or the |
641 | * total number of characters written for a type that belongs | 641 | * total number of characters written for a type that belongs |
642 | * to the IIO_VAL_... constant. | 642 | * to the IIO_VAL_* constant. |
643 | */ | 643 | */ |
644 | ssize_t iio_format_value(char *buf, unsigned int type, int size, int *vals) | 644 | ssize_t iio_format_value(char *buf, unsigned int type, int size, int *vals) |
645 | { | 645 | { |
diff --git a/drivers/iio/proximity/sx9500.c b/drivers/iio/proximity/sx9500.c index 53c5d653e780..df23dbcc030a 100644 --- a/drivers/iio/proximity/sx9500.c +++ b/drivers/iio/proximity/sx9500.c | |||
@@ -869,6 +869,7 @@ static int sx9500_init_device(struct iio_dev *indio_dev) | |||
869 | static void sx9500_gpio_probe(struct i2c_client *client, | 869 | static void sx9500_gpio_probe(struct i2c_client *client, |
870 | struct sx9500_data *data) | 870 | struct sx9500_data *data) |
871 | { | 871 | { |
872 | struct gpio_desc *gpiod_int; | ||
872 | struct device *dev; | 873 | struct device *dev; |
873 | 874 | ||
874 | if (!client) | 875 | if (!client) |
@@ -876,6 +877,14 @@ static void sx9500_gpio_probe(struct i2c_client *client, | |||
876 | 877 | ||
877 | dev = &client->dev; | 878 | dev = &client->dev; |
878 | 879 | ||
880 | if (client->irq <= 0) { | ||
881 | gpiod_int = devm_gpiod_get(dev, SX9500_GPIO_INT, GPIOD_IN); | ||
882 | if (IS_ERR(gpiod_int)) | ||
883 | dev_err(dev, "gpio get irq failed\n"); | ||
884 | else | ||
885 | client->irq = gpiod_to_irq(gpiod_int); | ||
886 | } | ||
887 | |||
879 | data->gpiod_rst = devm_gpiod_get(dev, SX9500_GPIO_RESET, GPIOD_OUT_HIGH); | 888 | data->gpiod_rst = devm_gpiod_get(dev, SX9500_GPIO_RESET, GPIOD_OUT_HIGH); |
880 | if (IS_ERR(data->gpiod_rst)) { | 889 | if (IS_ERR(data->gpiod_rst)) { |
881 | dev_warn(dev, "gpio get reset pin failed\n"); | 890 | dev_warn(dev, "gpio get reset pin failed\n"); |
diff --git a/drivers/staging/ccree/ssi_hash.c b/drivers/staging/ccree/ssi_hash.c index d79090ed7f9c..1799d3f26a9e 100644 --- a/drivers/staging/ccree/ssi_hash.c +++ b/drivers/staging/ccree/ssi_hash.c | |||
@@ -1778,9 +1778,12 @@ static int ssi_ahash_import(struct ahash_request *req, const void *in) | |||
1778 | } | 1778 | } |
1779 | in += sizeof(u32); | 1779 | in += sizeof(u32); |
1780 | 1780 | ||
1781 | rc = ssi_hash_init(state, ctx); | 1781 | /* call init() to allocate bufs if the user hasn't */ |
1782 | if (rc) | 1782 | if (!state->digest_buff) { |
1783 | goto out; | 1783 | rc = ssi_hash_init(state, ctx); |
1784 | if (rc) | ||
1785 | goto out; | ||
1786 | } | ||
1784 | 1787 | ||
1785 | dma_sync_single_for_cpu(dev, state->digest_buff_dma_addr, | 1788 | dma_sync_single_for_cpu(dev, state->digest_buff_dma_addr, |
1786 | ctx->inter_digestsize, DMA_BIDIRECTIONAL); | 1789 | ctx->inter_digestsize, DMA_BIDIRECTIONAL); |
diff --git a/drivers/staging/comedi/drivers/ni_atmio.c b/drivers/staging/comedi/drivers/ni_atmio.c index 2d62a8c57332..ae6ed96d7874 100644 --- a/drivers/staging/comedi/drivers/ni_atmio.c +++ b/drivers/staging/comedi/drivers/ni_atmio.c | |||
@@ -361,3 +361,8 @@ static struct comedi_driver ni_atmio_driver = { | |||
361 | .detach = ni_atmio_detach, | 361 | .detach = ni_atmio_detach, |
362 | }; | 362 | }; |
363 | module_comedi_driver(ni_atmio_driver); | 363 | module_comedi_driver(ni_atmio_driver); |
364 | |||
365 | MODULE_AUTHOR("Comedi http://www.comedi.org"); | ||
366 | MODULE_DESCRIPTION("Comedi low-level driver"); | ||
367 | MODULE_LICENSE("GPL"); | ||
368 | |||
diff --git a/drivers/staging/octeon-usb/octeon-hcd.c b/drivers/staging/octeon-usb/octeon-hcd.c index 068aece25d37..cded30f145aa 100644 --- a/drivers/staging/octeon-usb/octeon-hcd.c +++ b/drivers/staging/octeon-usb/octeon-hcd.c | |||
@@ -394,7 +394,7 @@ struct octeon_hcd { | |||
394 | result = -1; \ | 394 | result = -1; \ |
395 | break; \ | 395 | break; \ |
396 | } else \ | 396 | } else \ |
397 | cvmx_wait(100); \ | 397 | __delay(100); \ |
398 | } \ | 398 | } \ |
399 | } while (0); \ | 399 | } while (0); \ |
400 | result; }) | 400 | result; }) |
@@ -774,7 +774,7 @@ retry: | |||
774 | usbn_clk_ctl.s.hclk_rst = 1; | 774 | usbn_clk_ctl.s.hclk_rst = 1; |
775 | cvmx_write64_uint64(CVMX_USBNX_CLK_CTL(usb->index), usbn_clk_ctl.u64); | 775 | cvmx_write64_uint64(CVMX_USBNX_CLK_CTL(usb->index), usbn_clk_ctl.u64); |
776 | /* 2e. Wait 64 core-clock cycles for HCLK to stabilize */ | 776 | /* 2e. Wait 64 core-clock cycles for HCLK to stabilize */ |
777 | cvmx_wait(64); | 777 | __delay(64); |
778 | /* | 778 | /* |
779 | * 3. Program the power-on reset field in the USBN clock-control | 779 | * 3. Program the power-on reset field in the USBN clock-control |
780 | * register: | 780 | * register: |
@@ -795,7 +795,7 @@ retry: | |||
795 | cvmx_write64_uint64(CVMX_USBNX_USBP_CTL_STATUS(usb->index), | 795 | cvmx_write64_uint64(CVMX_USBNX_USBP_CTL_STATUS(usb->index), |
796 | usbn_usbp_ctl_status.u64); | 796 | usbn_usbp_ctl_status.u64); |
797 | /* 6. Wait 10 cycles */ | 797 | /* 6. Wait 10 cycles */ |
798 | cvmx_wait(10); | 798 | __delay(10); |
799 | /* | 799 | /* |
800 | * 7. Clear ATE_RESET field in the USBN clock-control register: | 800 | * 7. Clear ATE_RESET field in the USBN clock-control register: |
801 | * USBN_USBP_CTL_STATUS[ATE_RESET] = 0 | 801 | * USBN_USBP_CTL_STATUS[ATE_RESET] = 0 |
diff --git a/drivers/staging/rtl8188eu/os_dep/ioctl_linux.c b/drivers/staging/rtl8188eu/os_dep/ioctl_linux.c index c0664dc80bf2..446310775e90 100644 --- a/drivers/staging/rtl8188eu/os_dep/ioctl_linux.c +++ b/drivers/staging/rtl8188eu/os_dep/ioctl_linux.c | |||
@@ -1395,19 +1395,13 @@ static int rtw_wx_get_essid(struct net_device *dev, | |||
1395 | if ((check_fwstate(pmlmepriv, _FW_LINKED)) || | 1395 | if ((check_fwstate(pmlmepriv, _FW_LINKED)) || |
1396 | (check_fwstate(pmlmepriv, WIFI_ADHOC_MASTER_STATE))) { | 1396 | (check_fwstate(pmlmepriv, WIFI_ADHOC_MASTER_STATE))) { |
1397 | len = pcur_bss->Ssid.SsidLength; | 1397 | len = pcur_bss->Ssid.SsidLength; |
1398 | |||
1399 | wrqu->essid.length = len; | ||
1400 | |||
1401 | memcpy(extra, pcur_bss->Ssid.Ssid, len); | 1398 | memcpy(extra, pcur_bss->Ssid.Ssid, len); |
1402 | |||
1403 | wrqu->essid.flags = 1; | ||
1404 | } else { | 1399 | } else { |
1405 | ret = -1; | 1400 | len = 0; |
1406 | goto exit; | 1401 | *extra = 0; |
1407 | } | 1402 | } |
1408 | 1403 | wrqu->essid.length = len; | |
1409 | exit: | 1404 | wrqu->essid.flags = 1; |
1410 | |||
1411 | 1405 | ||
1412 | return ret; | 1406 | return ret; |
1413 | } | 1407 | } |
diff --git a/include/linux/iio/timer/stm32-lptim-trigger.h b/include/linux/iio/timer/stm32-lptim-trigger.h index 34d59bfdce2d..464458d20b16 100644 --- a/include/linux/iio/timer/stm32-lptim-trigger.h +++ b/include/linux/iio/timer/stm32-lptim-trigger.h | |||
@@ -16,11 +16,14 @@ | |||
16 | #define LPTIM2_OUT "lptim2_out" | 16 | #define LPTIM2_OUT "lptim2_out" |
17 | #define LPTIM3_OUT "lptim3_out" | 17 | #define LPTIM3_OUT "lptim3_out" |
18 | 18 | ||
19 | #if IS_ENABLED(CONFIG_IIO_STM32_LPTIMER_TRIGGER) | 19 | #if IS_REACHABLE(CONFIG_IIO_STM32_LPTIMER_TRIGGER) |
20 | bool is_stm32_lptim_trigger(struct iio_trigger *trig); | 20 | bool is_stm32_lptim_trigger(struct iio_trigger *trig); |
21 | #else | 21 | #else |
22 | static inline bool is_stm32_lptim_trigger(struct iio_trigger *trig) | 22 | static inline bool is_stm32_lptim_trigger(struct iio_trigger *trig) |
23 | { | 23 | { |
24 | #if IS_ENABLED(CONFIG_IIO_STM32_LPTIMER_TRIGGER) | ||
25 | pr_warn_once("stm32 lptim_trigger not linked in\n"); | ||
26 | #endif | ||
24 | return false; | 27 | return false; |
25 | } | 28 | } |
26 | #endif | 29 | #endif |