Skip to content

Commit

Permalink
Merge remote-tracking branch 'tip/timers/core' into afs-next
Browse files Browse the repository at this point in the history
These AFS patches need the timer_reduce() patch from timers/core.

Signed-off-by: David Howells <dhowells@redhat.com>
  • Loading branch information
dhowells committed Nov 13, 2017
2 parents ede372d + b24591e commit 81445e6
Show file tree
Hide file tree
Showing 251 changed files with 1,810 additions and 1,860 deletions.
24 changes: 12 additions & 12 deletions Documentation/devicetree/bindings/timer/renesas,cmt.txt
Original file line number Diff line number Diff line change
Expand Up @@ -20,16 +20,16 @@ Required Properties:
(CMT1 on sh73a0 and r8a7740)
This is a fallback for the above renesas,cmt-48-* entries.

- "renesas,cmt0-r8a73a4" for the 32-bit CMT0 device included in r8a73a4.
- "renesas,cmt1-r8a73a4" for the 48-bit CMT1 device included in r8a73a4.
- "renesas,cmt0-r8a7790" for the 32-bit CMT0 device included in r8a7790.
- "renesas,cmt1-r8a7790" for the 48-bit CMT1 device included in r8a7790.
- "renesas,cmt0-r8a7791" for the 32-bit CMT0 device included in r8a7791.
- "renesas,cmt1-r8a7791" for the 48-bit CMT1 device included in r8a7791.
- "renesas,cmt0-r8a7793" for the 32-bit CMT0 device included in r8a7793.
- "renesas,cmt1-r8a7793" for the 48-bit CMT1 device included in r8a7793.
- "renesas,cmt0-r8a7794" for the 32-bit CMT0 device included in r8a7794.
- "renesas,cmt1-r8a7794" for the 48-bit CMT1 device included in r8a7794.
- "renesas,r8a73a4-cmt0" for the 32-bit CMT0 device included in r8a73a4.
- "renesas,r8a73a4-cmt1" for the 48-bit CMT1 device included in r8a73a4.
- "renesas,r8a7790-cmt0" for the 32-bit CMT0 device included in r8a7790.
- "renesas,r8a7790-cmt1" for the 48-bit CMT1 device included in r8a7790.
- "renesas,r8a7791-cmt0" for the 32-bit CMT0 device included in r8a7791.
- "renesas,r8a7791-cmt1" for the 48-bit CMT1 device included in r8a7791.
- "renesas,r8a7793-cmt0" for the 32-bit CMT0 device included in r8a7793.
- "renesas,r8a7793-cmt1" for the 48-bit CMT1 device included in r8a7793.
- "renesas,r8a7794-cmt0" for the 32-bit CMT0 device included in r8a7794.
- "renesas,r8a7794-cmt1" for the 48-bit CMT1 device included in r8a7794.

- "renesas,rcar-gen2-cmt0" for 32-bit CMT0 devices included in R-Car Gen2.
- "renesas,rcar-gen2-cmt1" for 48-bit CMT1 devices included in R-Car Gen2.
Expand All @@ -46,7 +46,7 @@ Required Properties:
Example: R8A7790 (R-Car H2) CMT0 and CMT1 nodes

cmt0: timer@ffca0000 {
compatible = "renesas,cmt0-r8a7790", "renesas,rcar-gen2-cmt0";
compatible = "renesas,r8a7790-cmt0", "renesas,rcar-gen2-cmt0";
reg = <0 0xffca0000 0 0x1004>;
interrupts = <0 142 IRQ_TYPE_LEVEL_HIGH>,
<0 142 IRQ_TYPE_LEVEL_HIGH>;
Expand All @@ -55,7 +55,7 @@ Example: R8A7790 (R-Car H2) CMT0 and CMT1 nodes
};

cmt1: timer@e6130000 {
compatible = "renesas,cmt1-r8a7790", "renesas,rcar-gen2-cmt1";
compatible = "renesas,r8a7790-cmt1", "renesas,rcar-gen2-cmt1";
reg = <0 0xe6130000 0 0x1004>;
interrupts = <0 120 IRQ_TYPE_LEVEL_HIGH>,
<0 121 IRQ_TYPE_LEVEL_HIGH>,
Expand Down
3 changes: 2 additions & 1 deletion MAINTAINERS
Original file line number Diff line number Diff line change
Expand Up @@ -3450,7 +3450,8 @@ M: Thomas Gleixner <tglx@linutronix.de>
L: linux-kernel@vger.kernel.org
T: git git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip.git timers/core
S: Supported
F: drivers/clocksource
F: drivers/clocksource/
F: Documentation/devicetree/bindings/timer/

CMPC ACPI DRIVER
M: Thadeu Lima de Souza Cascardo <cascardo@holoscopio.com>
Expand Down
26 changes: 8 additions & 18 deletions arch/arm/mach-footbridge/dc21285.c
Original file line number Diff line number Diff line change
Expand Up @@ -136,19 +136,14 @@ struct pci_ops dc21285_ops = {
static struct timer_list serr_timer;
static struct timer_list perr_timer;

static void dc21285_enable_error(unsigned long __data)
static void dc21285_enable_error(struct timer_list *timer)
{
switch (__data) {
case IRQ_PCI_SERR:
del_timer(&serr_timer);
break;

case IRQ_PCI_PERR:
del_timer(&perr_timer);
break;
}
del_timer(timer);

enable_irq(__data);
if (timer == &serr_timer)
enable_irq(IRQ_PCI_SERR);
else if (timer == &perr_timer)
enable_irq(IRQ_PCI_PERR);
}

/*
Expand Down Expand Up @@ -323,13 +318,8 @@ void __init dc21285_preinit(void)
*CSR_PCICMD = (*CSR_PCICMD & 0xffff) | PCICMD_ERROR_BITS;
}

init_timer(&serr_timer);
init_timer(&perr_timer);

serr_timer.data = IRQ_PCI_SERR;
serr_timer.function = dc21285_enable_error;
perr_timer.data = IRQ_PCI_PERR;
perr_timer.function = dc21285_enable_error;
timer_setup(&serr_timer, dc21285_enable_error, 0);
timer_setup(&perr_timer, dc21285_enable_error, 0);

/*
* We don't care if these fail.
Expand Down
2 changes: 1 addition & 1 deletion arch/arm/mach-ixp4xx/dsmg600-setup.c
Original file line number Diff line number Diff line change
Expand Up @@ -175,7 +175,7 @@ static int power_button_countdown;
#define PBUTTON_HOLDDOWN_COUNT 4 /* 2 secs */

static void dsmg600_power_handler(unsigned long data);
static DEFINE_TIMER(dsmg600_power_timer, dsmg600_power_handler, 0, 0);
static DEFINE_TIMER(dsmg600_power_timer, dsmg600_power_handler);

static void dsmg600_power_handler(unsigned long data)
{
Expand Down
2 changes: 1 addition & 1 deletion arch/arm/mach-ixp4xx/nas100d-setup.c
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,7 @@ static int power_button_countdown;
#define PBUTTON_HOLDDOWN_COUNT 4 /* 2 secs */

static void nas100d_power_handler(unsigned long data);
static DEFINE_TIMER(nas100d_power_timer, nas100d_power_handler, 0, 0);
static DEFINE_TIMER(nas100d_power_timer, nas100d_power_handler);

static void nas100d_power_handler(unsigned long data)
{
Expand Down
15 changes: 6 additions & 9 deletions arch/arm/mach-pxa/lubbock.c
Original file line number Diff line number Diff line change
Expand Up @@ -381,14 +381,11 @@ static struct pxafb_mach_info sharp_lm8v31 = {

#define MMC_POLL_RATE msecs_to_jiffies(1000)

static void lubbock_mmc_poll(unsigned long);
static irq_handler_t mmc_detect_int;
static void *mmc_detect_int_data;
static struct timer_list mmc_timer;

static struct timer_list mmc_timer = {
.function = lubbock_mmc_poll,
};

static void lubbock_mmc_poll(unsigned long data)
static void lubbock_mmc_poll(struct timer_list *unused)
{
unsigned long flags;

Expand All @@ -401,7 +398,7 @@ static void lubbock_mmc_poll(unsigned long data)
if (LUB_IRQ_SET_CLR & (1 << 0))
mod_timer(&mmc_timer, jiffies + MMC_POLL_RATE);
else {
(void) mmc_detect_int(LUBBOCK_SD_IRQ, (void *)data);
(void) mmc_detect_int(LUBBOCK_SD_IRQ, mmc_detect_int_data);
enable_irq(LUBBOCK_SD_IRQ);
}
}
Expand All @@ -421,8 +418,8 @@ static int lubbock_mci_init(struct device *dev,
{
/* detect card insert/eject */
mmc_detect_int = detect_int;
init_timer(&mmc_timer);
mmc_timer.data = (unsigned long) data;
mmc_detect_int_data = data;
timer_setup(&mmc_timer, lubbock_mmc_poll, 0);
return request_irq(LUBBOCK_SD_IRQ, lubbock_detect_int,
0, "lubbock-sd-detect", data);
}
Expand Down
8 changes: 4 additions & 4 deletions arch/arm/mach-pxa/sharpsl_pm.c
Original file line number Diff line number Diff line change
Expand Up @@ -341,7 +341,7 @@ static void sharpsl_charge_toggle(struct work_struct *private_)
sharpsl_pm.charge_start_time = jiffies;
}

static void sharpsl_ac_timer(unsigned long data)
static void sharpsl_ac_timer(struct timer_list *unused)
{
int acin = sharpsl_pm.machinfo->read_devdata(SHARPSL_STATUS_ACIN);

Expand All @@ -366,7 +366,7 @@ static irqreturn_t sharpsl_ac_isr(int irq, void *dev_id)
return IRQ_HANDLED;
}

static void sharpsl_chrg_full_timer(unsigned long data)
static void sharpsl_chrg_full_timer(struct timer_list *unused)
{
dev_dbg(sharpsl_pm.dev, "Charge Full at time: %lx\n", jiffies);

Expand Down Expand Up @@ -841,9 +841,9 @@ static int sharpsl_pm_probe(struct platform_device *pdev)
sharpsl_pm.charge_mode = CHRG_OFF;
sharpsl_pm.flags = 0;

setup_timer(&sharpsl_pm.ac_timer, sharpsl_ac_timer, 0UL);
timer_setup(&sharpsl_pm.ac_timer, sharpsl_ac_timer, 0);

setup_timer(&sharpsl_pm.chrg_full_timer, sharpsl_chrg_full_timer, 0UL);
timer_setup(&sharpsl_pm.chrg_full_timer, sharpsl_chrg_full_timer, 0);

led_trigger_register_simple("sharpsl-charge", &sharpsl_charge_led_trigger);

Expand Down
4 changes: 3 additions & 1 deletion arch/ia64/include/asm/sn/bte.h
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@
#include <asm/sn/types.h>
#include <asm/sn/shub_mmr.h>

struct nodepda_s;

#define IBCT_NOTIFY (0x1UL << 4)
#define IBCT_ZFIL_MODE (0x1UL << 0)

Expand Down Expand Up @@ -210,7 +212,7 @@ struct bteinfo_s {
*/
extern bte_result_t bte_copy(u64, u64, u64, u64, void *);
extern bte_result_t bte_unaligned_copy(u64, u64, u64, u64);
extern void bte_error_handler(unsigned long);
extern void bte_error_handler(struct nodepda_s *);

#define bte_zero(dest, len, mode, notification) \
bte_copy(0, dest, len, ((mode) | BTE_ZERO_FILL), notification)
Expand Down
8 changes: 4 additions & 4 deletions arch/ia64/kernel/mca.c
Original file line number Diff line number Diff line change
Expand Up @@ -1513,7 +1513,7 @@ ia64_mca_cmc_int_caller(int cmc_irq, void *arg)
*
*/
static void
ia64_mca_cmc_poll (unsigned long dummy)
ia64_mca_cmc_poll (struct timer_list *unused)
{
/* Trigger a CMC interrupt cascade */
platform_send_ipi(cpumask_first(cpu_online_mask), IA64_CMCP_VECTOR,
Expand Down Expand Up @@ -1590,7 +1590,7 @@ ia64_mca_cpe_int_caller(int cpe_irq, void *arg)
*
*/
static void
ia64_mca_cpe_poll (unsigned long dummy)
ia64_mca_cpe_poll (struct timer_list *unused)
{
/* Trigger a CPE interrupt cascade */
platform_send_ipi(cpumask_first(cpu_online_mask), IA64_CPEP_VECTOR,
Expand Down Expand Up @@ -2098,7 +2098,7 @@ ia64_mca_late_init(void)
return 0;

/* Setup the CMCI/P vector and handler */
setup_timer(&cmc_poll_timer, ia64_mca_cmc_poll, 0UL);
timer_setup(&cmc_poll_timer, ia64_mca_cmc_poll, 0);

/* Unmask/enable the vector */
cmc_polling_enabled = 0;
Expand All @@ -2109,7 +2109,7 @@ ia64_mca_late_init(void)
#ifdef CONFIG_ACPI
/* Setup the CPEI/P vector and handler */
cpe_vector = acpi_request_vector(ACPI_INTERRUPT_CPEI);
setup_timer(&cpe_poll_timer, ia64_mca_cpe_poll, 0UL);
timer_setup(&cpe_poll_timer, ia64_mca_cpe_poll, 0);

{
unsigned int irq;
Expand Down
5 changes: 2 additions & 3 deletions arch/ia64/kernel/salinfo.c
Original file line number Diff line number Diff line change
Expand Up @@ -263,7 +263,7 @@ salinfo_timeout_check(struct salinfo_data *data)
}

static void
salinfo_timeout (unsigned long arg)
salinfo_timeout(struct timer_list *unused)
{
ia64_mlogbuf_dump();
salinfo_timeout_check(salinfo_data + SAL_INFO_TYPE_MCA);
Expand Down Expand Up @@ -623,9 +623,8 @@ salinfo_init(void)

*sdir++ = salinfo_dir;

init_timer(&salinfo_timer);
timer_setup(&salinfo_timer, salinfo_timeout, 0);
salinfo_timer.expires = jiffies + SALINFO_TIMER_DELAY;
salinfo_timer.function = &salinfo_timeout;
add_timer(&salinfo_timer);

i = cpuhp_setup_state(CPUHP_AP_ONLINE_DYN, "ia64/salinfo:online",
Expand Down
12 changes: 8 additions & 4 deletions arch/ia64/sn/kernel/bte.c
Original file line number Diff line number Diff line change
Expand Up @@ -219,7 +219,7 @@ bte_result_t bte_copy(u64 src, u64 dest, u64 len, u64 mode, void *notification)
BTE_LNSTAT_LOAD(bte), *bte->most_rcnt_na) );
bte->bte_error_count++;
bte->bh_error = IBLS_ERROR;
bte_error_handler((unsigned long)NODEPDA(bte->bte_cnode));
bte_error_handler(NODEPDA(bte->bte_cnode));
*bte->most_rcnt_na = BTE_WORD_AVAILABLE;
goto retry_bteop;
}
Expand Down Expand Up @@ -414,6 +414,12 @@ EXPORT_SYMBOL(bte_unaligned_copy);
* Block Transfer Engine initialization functions.
*
***********************************************************************/
static void bte_recovery_timeout(struct timer_list *t)
{
struct nodepda_s *nodepda = from_timer(nodepda, t, bte_recovery_timer);

bte_error_handler(nodepda);
}

/*
* bte_init_node(nodepda, cnode)
Expand All @@ -436,9 +442,7 @@ void bte_init_node(nodepda_t * mynodepda, cnodeid_t cnode)
* will point at this one bte_recover structure to get the lock.
*/
spin_lock_init(&mynodepda->bte_recovery_lock);
init_timer(&mynodepda->bte_recovery_timer);
mynodepda->bte_recovery_timer.function = bte_error_handler;
mynodepda->bte_recovery_timer.data = (unsigned long)mynodepda;
timer_setup(&mynodepda->bte_recovery_timer, bte_recovery_timeout, 0);

for (i = 0; i < BTES_PER_NODE; i++) {
u64 *base_addr;
Expand Down
17 changes: 6 additions & 11 deletions arch/ia64/sn/kernel/bte_error.c
Original file line number Diff line number Diff line change
Expand Up @@ -27,15 +27,12 @@
* transfers to be queued.
*/

void bte_error_handler(unsigned long);

/*
* Wait until all BTE related CRBs are completed
* and then reset the interfaces.
*/
int shub1_bte_error_handler(unsigned long _nodepda)
static int shub1_bte_error_handler(struct nodepda_s *err_nodepda)
{
struct nodepda_s *err_nodepda = (struct nodepda_s *)_nodepda;
struct timer_list *recovery_timer = &err_nodepda->bte_recovery_timer;
nasid_t nasid;
int i;
Expand Down Expand Up @@ -131,9 +128,8 @@ int shub1_bte_error_handler(unsigned long _nodepda)
* Wait until all BTE related CRBs are completed
* and then reset the interfaces.
*/
int shub2_bte_error_handler(unsigned long _nodepda)
static int shub2_bte_error_handler(struct nodepda_s *err_nodepda)
{
struct nodepda_s *err_nodepda = (struct nodepda_s *)_nodepda;
struct timer_list *recovery_timer = &err_nodepda->bte_recovery_timer;
struct bteinfo_s *bte;
nasid_t nasid;
Expand Down Expand Up @@ -170,9 +166,8 @@ int shub2_bte_error_handler(unsigned long _nodepda)
* Wait until all BTE related CRBs are completed
* and then reset the interfaces.
*/
void bte_error_handler(unsigned long _nodepda)
void bte_error_handler(struct nodepda_s *err_nodepda)
{
struct nodepda_s *err_nodepda = (struct nodepda_s *)_nodepda;
spinlock_t *recovery_lock = &err_nodepda->bte_recovery_lock;
int i;
unsigned long irq_flags;
Expand All @@ -199,12 +194,12 @@ void bte_error_handler(unsigned long _nodepda)
}

if (is_shub1()) {
if (shub1_bte_error_handler(_nodepda)) {
if (shub1_bte_error_handler(err_nodepda)) {
spin_unlock_irqrestore(recovery_lock, irq_flags);
return;
}
} else {
if (shub2_bte_error_handler(_nodepda)) {
if (shub2_bte_error_handler(err_nodepda)) {
spin_unlock_irqrestore(recovery_lock, irq_flags);
return;
}
Expand Down Expand Up @@ -255,6 +250,6 @@ bte_crb_error_handler(cnodeid_t cnode, int btenum,

BTE_PRINTK(("Got an error on cnode %d bte %d: HW error type 0x%x\n",
bte->bte_cnode, bte->bte_num, ioe->ie_errortype));
bte_error_handler((unsigned long) NODEPDA(cnode));
bte_error_handler(NODEPDA(cnode));
}

2 changes: 1 addition & 1 deletion arch/ia64/sn/kernel/huberror.c
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ static irqreturn_t hub_eint_handler(int irq, void *arg)
if ((int)ret_stuff.v0)
panic("%s: Fatal TIO Error", __func__);
} else
bte_error_handler((unsigned long)NODEPDA(nasid_to_cnodeid(nasid)));
bte_error_handler(NODEPDA(nasid_to_cnodeid(nasid)));

return IRQ_HANDLED;
}
Expand Down
5 changes: 2 additions & 3 deletions arch/ia64/sn/kernel/mca.c
Original file line number Diff line number Diff line change
Expand Up @@ -72,17 +72,16 @@ static void sn_cpei_handler(int irq, void *devid, struct pt_regs *regs)
ia64_sn_plat_cpei_handler();
}

static void sn_cpei_timer_handler(unsigned long dummy)
static void sn_cpei_timer_handler(struct timer_list *unused)
{
sn_cpei_handler(-1, NULL, NULL);
mod_timer(&sn_cpei_timer, jiffies + CPEI_INTERVAL);
}

void sn_init_cpei_timer(void)
{
init_timer(&sn_cpei_timer);
timer_setup(&sn_cpei_timer, sn_cpei_timer_handler, 0);
sn_cpei_timer.expires = jiffies + CPEI_INTERVAL;
sn_cpei_timer.function = sn_cpei_timer_handler;
add_timer(&sn_cpei_timer);
}

Expand Down
2 changes: 1 addition & 1 deletion arch/m68k/amiga/amisound.c
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ void __init amiga_init_sound(void)
}

static void nosound( unsigned long ignored );
static DEFINE_TIMER(sound_timer, nosound, 0, 0);
static DEFINE_TIMER(sound_timer, nosound);

void amiga_mksound( unsigned int hz, unsigned int ticks )
{
Expand Down
2 changes: 1 addition & 1 deletion arch/m68k/mac/macboing.c
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ static void ( *mac_special_bell )( unsigned int, unsigned int, unsigned int );
/*
* our timer to start/continue/stop the bell
*/
static DEFINE_TIMER(mac_sound_timer, mac_nosound, 0, 0);
static DEFINE_TIMER(mac_sound_timer, mac_nosound);

/*
* Sort of initialize the sound chip (called from mac_mksound on the first
Expand Down
Loading

0 comments on commit 81445e6

Please sign in to comment.