Merge branch 'akpm' (patches from Andrew)
Pull updates from Andrew Morton: "Most of -mm and quite a number of other subsystems: hotfixes, scripts, ocfs2, misc, lib, binfmt, init, reiserfs, exec, dma-mapping, kcov. MM is fairly quiet this time. Holidays, I assume" * emailed patches from Andrew Morton <akpm@linux-foundation.org>: (118 commits) kcov: ignore fault-inject and stacktrace include/linux/io-mapping.h-mapping: use PHYS_PFN() macro in io_mapping_map_atomic_wc() execve: warn if process starts with executable stack reiserfs: prevent NULL pointer dereference in reiserfs_insert_item() init/main.c: fix misleading "This architecture does not have kernel memory protection" message init/main.c: fix quoted value handling in unknown_bootoption init/main.c: remove unnecessary repair_env_string in do_initcall_level init/main.c: log arguments and environment passed to init fs/binfmt_elf.c: coredump: allow process with empty address space to coredump fs/binfmt_elf.c: coredump: delete duplicated overflow check fs/binfmt_elf.c: coredump: allocate core ELF header on stack fs/binfmt_elf.c: make BAD_ADDR() unlikely fs/binfmt_elf.c: better codegen around current->mm fs/binfmt_elf.c: don't copy ELF header around fs/binfmt_elf.c: fix ->start_code calculation fs/binfmt_elf.c: smaller code generation around auxv vector fill lib/find_bit.c: uninline helper _find_next_bit() lib/find_bit.c: join _find_next_bit{_le} uapi: rename ext2_swab() to swab() and share globally in swab.h lib/scatterlist.c: adjust indentation in __sg_alloc_table ...
This commit is contained in:
@@ -296,7 +296,6 @@ static inline void bnx2x_dcb_config_qm(struct bnx2x *bp, enum cos_mode mode,
|
||||
* possible, the driver should only write the valid vnics into the internal
|
||||
* ram according to the appropriate port mode.
|
||||
*/
|
||||
#define BITS_TO_BYTES(x) ((x)/8)
|
||||
|
||||
/* CMNG constants, as derived from system spec calculations */
|
||||
|
||||
|
||||
@@ -27,6 +27,7 @@
|
||||
#include <linux/firmware.h>
|
||||
#include <linux/etherdevice.h>
|
||||
#include <linux/if_arp.h>
|
||||
#include <linux/units.h>
|
||||
|
||||
#include <net/mac80211.h>
|
||||
|
||||
@@ -6468,7 +6469,7 @@ il4965_set_hw_params(struct il_priv *il)
|
||||
il->hw_params.valid_rx_ant = il->cfg->valid_rx_ant;
|
||||
|
||||
il->hw_params.ct_kill_threshold =
|
||||
CELSIUS_TO_KELVIN(CT_KILL_THRESHOLD_LEGACY);
|
||||
celsius_to_kelvin(CT_KILL_THRESHOLD_LEGACY);
|
||||
|
||||
il->hw_params.sens = &il4965_sensitivity;
|
||||
il->hw_params.beacon_time_tsf_bits = IL4965_EXT_BEACON_TIME_POS;
|
||||
|
||||
@@ -17,6 +17,7 @@
|
||||
#include <linux/sched.h>
|
||||
#include <linux/skbuff.h>
|
||||
#include <linux/netdevice.h>
|
||||
#include <linux/units.h>
|
||||
#include <net/mac80211.h>
|
||||
#include <linux/etherdevice.h>
|
||||
#include <asm/unaligned.h>
|
||||
@@ -1104,7 +1105,7 @@ il4965_fill_txpower_tbl(struct il_priv *il, u8 band, u16 channel, u8 is_ht40,
|
||||
/* get current temperature (Celsius) */
|
||||
current_temp = max(il->temperature, IL_TX_POWER_TEMPERATURE_MIN);
|
||||
current_temp = min(il->temperature, IL_TX_POWER_TEMPERATURE_MAX);
|
||||
current_temp = KELVIN_TO_CELSIUS(current_temp);
|
||||
current_temp = kelvin_to_celsius(current_temp);
|
||||
|
||||
/* select thermal txpower adjustment params, based on channel group
|
||||
* (same frequency group used for mimo txatten adjustment) */
|
||||
@@ -1610,8 +1611,8 @@ il4965_hw_get_temperature(struct il_priv *il)
|
||||
temperature =
|
||||
(temperature * 97) / 100 + TEMPERATURE_CALIB_KELVIN_OFFSET;
|
||||
|
||||
D_TEMP("Calibrated temperature: %dK, %dC\n", temperature,
|
||||
KELVIN_TO_CELSIUS(temperature));
|
||||
D_TEMP("Calibrated temperature: %dK, %ldC\n", temperature,
|
||||
kelvin_to_celsius(temperature));
|
||||
|
||||
return temperature;
|
||||
}
|
||||
@@ -1670,12 +1671,12 @@ il4965_temperature_calib(struct il_priv *il)
|
||||
|
||||
if (il->temperature != temp) {
|
||||
if (il->temperature)
|
||||
D_TEMP("Temperature changed " "from %dC to %dC\n",
|
||||
KELVIN_TO_CELSIUS(il->temperature),
|
||||
KELVIN_TO_CELSIUS(temp));
|
||||
D_TEMP("Temperature changed " "from %ldC to %ldC\n",
|
||||
kelvin_to_celsius(il->temperature),
|
||||
kelvin_to_celsius(temp));
|
||||
else
|
||||
D_TEMP("Temperature " "initialized to %dC\n",
|
||||
KELVIN_TO_CELSIUS(temp));
|
||||
D_TEMP("Temperature " "initialized to %ldC\n",
|
||||
kelvin_to_celsius(temp));
|
||||
}
|
||||
|
||||
il->temperature = temp;
|
||||
|
||||
@@ -779,9 +779,6 @@ struct il_sensitivity_ranges {
|
||||
u16 nrg_th_cca;
|
||||
};
|
||||
|
||||
#define KELVIN_TO_CELSIUS(x) ((x)-273)
|
||||
#define CELSIUS_TO_KELVIN(x) ((x)+273)
|
||||
|
||||
/**
|
||||
* struct il_hw_params
|
||||
* @bcast_id: f/w broadcast station ID
|
||||
|
||||
@@ -237,11 +237,6 @@ struct iwl_sensitivity_ranges {
|
||||
u16 nrg_th_cca;
|
||||
};
|
||||
|
||||
|
||||
#define KELVIN_TO_CELSIUS(x) ((x)-273)
|
||||
#define CELSIUS_TO_KELVIN(x) ((x)+273)
|
||||
|
||||
|
||||
/******************************************************************************
|
||||
*
|
||||
* Functions implemented in core module which are forward declared here
|
||||
|
||||
@@ -10,6 +10,8 @@
|
||||
*
|
||||
*****************************************************************************/
|
||||
|
||||
#include <linux/units.h>
|
||||
|
||||
/*
|
||||
* DVM device-specific data & functions
|
||||
*/
|
||||
@@ -345,7 +347,7 @@ static s32 iwl_temp_calib_to_offset(struct iwl_priv *priv)
|
||||
static void iwl5150_set_ct_threshold(struct iwl_priv *priv)
|
||||
{
|
||||
const s32 volt2temp_coef = IWL_5150_VOLTAGE_TO_TEMPERATURE_COEFF;
|
||||
s32 threshold = (s32)CELSIUS_TO_KELVIN(CT_KILL_THRESHOLD_LEGACY) -
|
||||
s32 threshold = (s32)celsius_to_kelvin(CT_KILL_THRESHOLD_LEGACY) -
|
||||
iwl_temp_calib_to_offset(priv);
|
||||
|
||||
priv->hw_params.ct_kill_threshold = threshold * volt2temp_coef;
|
||||
@@ -381,7 +383,7 @@ static void iwl5150_temperature(struct iwl_priv *priv)
|
||||
vt = le32_to_cpu(priv->statistics.common.temperature);
|
||||
vt = vt / IWL_5150_VOLTAGE_TO_TEMPERATURE_COEFF + offset;
|
||||
/* now vt hold the temperature in Kelvin */
|
||||
priv->temperature = KELVIN_TO_CELSIUS(vt);
|
||||
priv->temperature = kelvin_to_celsius(vt);
|
||||
iwl_tt_handler(priv);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user