Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 0958ceaa authored by Prasad Sodagudi's avatar Prasad Sodagudi Committed by Sridhar Parasuram
Browse files

drivers: Warning fixes to disable CC_OPTIMIZE_FOR_SIZE



These are all driver changes needed for disablement of
CONFIG_CC_OPTIMIZE_FOR_SIZE. CONFIG_CC_OPTIMIZE_FOR_PERFORMANCE
is enabled by default once CONFIG_CC_OPTIMIZE_FOR_SIZE is disabled.

Change-Id: Ia46a1f24e8a082a29ea6151e41e6d3a85a05fd4f
Signed-off-by: default avatarPrasad Sodagudi <psodagud@codeaurora.org>
Signed-off-by: default avatarSridhar Parasuram <sridhar@codeaurora.org>
parent 60be7160
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
/* Copyright (c) 2009-2010, 2013-2016 The Linux Foundation. All rights reserved.
/* Copyright (c) 2009-2010, 2013-2017 The Linux Foundation. All rights reserved.
 *
 * This program is free software; you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 2 and
@@ -682,7 +682,7 @@ int bt_register_slimdev(struct device *dev)

static long bt_ioctl(struct file *file, unsigned int cmd, unsigned long arg)
{
	int ret, pwr_cntrl = 0;
	int ret = 0, pwr_cntrl = 0;

	switch (cmd) {
	case BT_CMD_SLIM_TEST:
+2 −2
Original line number Diff line number Diff line
@@ -293,9 +293,9 @@ static int btfm_slim_dai_get_channel_map(struct snd_soc_dai *dai,
				 unsigned int *tx_num, unsigned int *tx_slot,
				 unsigned int *rx_num, unsigned int *rx_slot)
{
	int i, ret = -EINVAL, *slot, j = 0, num = 1;
	int i, ret = -EINVAL, *slot = NULL, j = 0, num = 1;
	struct btfmslim *btfmslim = dai->dev->platform_data;
	struct btfmslim_ch *ch;
	struct btfmslim_ch *ch = NULL;

	if (!btfmslim)
		return ret;
+3 −3
Original line number Diff line number Diff line
@@ -1541,8 +1541,8 @@ static int clk_osm_setup_hw_table(struct clk_osm *c)
{
	struct osm_entry *entry = c->osm_table;
	int i;
	u32 freq_val, volt_val, override_val, spare_val;
	u32 table_entry_offset, last_spare, last_virtual_corner = 0;
	u32 freq_val = 0, volt_val = 0, override_val = 0, spare_val = 0;
	u32 table_entry_offset = 0, last_spare = 0, last_virtual_corner = 0;

	for (i = 0; i < OSM_TABLE_SIZE; i++) {
		if (i < c->num_entries) {
@@ -2758,7 +2758,7 @@ static ssize_t debugfs_trace_method_get(struct file *file, char __user *buf,
					size_t count, loff_t *ppos)
{
	struct clk_osm *c = file->private_data;
	int len, rc;
	int len = 0, rc;

	if (IS_ERR(file) || file == NULL) {
		pr_err("input error %ld\n", PTR_ERR(file));
+1 −1
Original line number Diff line number Diff line
@@ -597,7 +597,7 @@ int acpi_dev_gpio_irq_get(struct acpi_device *adev, int index)
	int idx, i;

	for (i = 0, idx = 0; idx <= index; i++) {
		struct acpi_gpio_info info;
		struct acpi_gpio_info info = {0, 0};
		struct gpio_desc *desc;

		desc = acpi_get_gpiod_by_index(adev, NULL, i, &info);
+2 −1
Original line number Diff line number Diff line
@@ -687,7 +687,8 @@ static int qpnp_flash_led_get_voltage_headroom(struct qpnp_flash_led *led)
#define VIN_FLASH_MIN_UV	3300000LL
static int qpnp_flash_led_calc_max_current(struct qpnp_flash_led *led)
{
	int ocv_uv, rbatt_uohm, ibat_now, voltage_hdrm_mv, rc;
	int ocv_uv = 0, rbatt_uohm = 0, ibat_now = 0, voltage_hdrm_mv = 0;
	int rc = 0;
	int64_t ibat_flash_ua, avail_flash_ua, avail_flash_power_fw;
	int64_t ibat_safe_ua, vin_flash_uv, vph_flash_uv, vph_flash_vdip;

Loading