2 * Based on the stubs for the ARM implementation which is:
4 * Created by: Nicolas Pitre, April 2012
5 * Copyright: (C) 2012-2013 Linaro Limited
7 * This program is free software; you can redistribute it and/or modify
8 * it under the terms of the GNU General Public License version 2 as
9 * published by the Free Software Foundation.
12 #ifndef ASM_BL_SWITCHER_H
13 #define ASM_BL_SWITCHER_H
15 #include <linux/notifier.h>
16 #include <linux/types.h>
18 typedef void (*bL_switch_completion_handler)(void *cookie);
20 static inline int bL_switch_request(unsigned int cpu,
21 unsigned int new_cluster_id)
27 * Register here to be notified about runtime enabling/disabling of
30 * The notifier chain is called with the switcher activation lock held:
31 * the switcher will not be enabled or disabled during callbacks.
32 * Callbacks must not call bL_switcher_{get,put}_enabled().
34 #define BL_NOTIFY_PRE_ENABLE 0
35 #define BL_NOTIFY_POST_ENABLE 1
36 #define BL_NOTIFY_PRE_DISABLE 2
37 #define BL_NOTIFY_POST_DISABLE 3
39 static inline int bL_switcher_register_notifier(struct notifier_block *nb)
44 static inline int bL_switcher_unregister_notifier(struct notifier_block *nb)
49 static inline bool bL_switcher_get_enabled(void) { return false; }
50 static inline void bL_switcher_put_enabled(void) { }
51 static inline int bL_switcher_trace_trigger(void) { return 0; }
52 static inline int bL_switcher_get_logical_index(u32 mpidr) { return -EUNATCH; }