This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
fig = pylab.figure() | |
ax = fig.add_subplot(111) | |
ax.yaxis.grid(color='gray', linestyle='dashed') | |
ax.xaxis.grid(color='gray', linestyle='dashed') | |
ax.plot(dates, data, 'o-') | |
fig.show() |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
In [44]: data | |
Out[44]: | |
[93184.0, | |
95047.68, | |
96948.63359999999, | |
100826.57894399998, | |
102843.11052287997, | |
104899.97273333758, | |
109095.97164267108, | |
111277.8910755245, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#define INIT_CALLS_LEVEL(level) \ | |
VMLINUX_SYMBOL(__initcall##level##_start) = .; \ | |
*(.initcall##level##.init) \ | |
*(.initcall##level##s.init) \ | |
#define INIT_CALLS \ | |
VMLINUX_SYMBOL(__initcall_start) = .; \ | |
*(.initcallearly.init) \ | |
INIT_CALLS_LEVEL(0) \ | |
INIT_CALLS_LEVEL(1) \ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
extern initcall_t __initcall_start[]; | |
extern initcall_t __initcall0_start[]; | |
extern initcall_t __initcall1_start[]; | |
extern initcall_t __initcall2_start[]; | |
extern initcall_t __initcall3_start[]; | |
extern initcall_t __initcall4_start[]; | |
extern initcall_t __initcall5_start[]; | |
extern initcall_t __initcall6_start[]; | |
extern initcall_t __initcall7_start[]; | |
extern initcall_t __initcall_end[]; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
static initcall_t *initcall_levels[] __initdata = { | |
__initcall0_start, | |
__initcall1_start, | |
__initcall2_start, | |
__initcall3_start, | |
__initcall4_start, | |
__initcall5_start, | |
__initcall6_start, | |
__initcall7_start, | |
__initcall_end, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
static void __init do_initcall_level(int level) | |
{ | |
initcall_t *fn; | |
/* ... */ | |
for (fn = initcall_levels[level]; fn < initcall_levels[level+1]; fn++) | |
do_one_initcall(*fn); | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
int __init_or_module do_one_initcall(initcall_t fn) | |
{ | |
int count = preempt_count(); | |
int ret; | |
/* ... */ | |
ret = fn(); | |
/* ... */ | |
return ret; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
static void __init do_initcall_level(int level) | |
{ | |
extern const struct kernel_param __start___param[], __stop___param[]; | |
initcall_t *fn; | |
strcpy(static_command_line, saved_command_line); | |
parse_args(initcall_level_names[level], | |
static_command_line, __start___param, | |
__stop___param - __start___param, | |
level, level, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include "section_hacking.h" | |
extern struct formatter_info __start_my_formatters; | |
extern struct formatter_info __stop_my_formatters; | |
static void format_all(const char *txt) | |
{ | |
struct formatter_info *iter = &__start_my_formatters; | |
for ( ; iter < &__stop_my_formatters; ++iter) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include "section_hacking.h" | |
extern struct formatter_info __start_my_formatters; | |
extern struct formatter_info __stop_my_formatters; | |
static void format_all(const char *txt) | |
{ | |
struct formatter_info *iter = &__start_my_formatters; | |
for ( ; iter < &__stop_my_formatters; ++iter) { |