summaryrefslogtreecommitdiff
path: root/screen.c
blob: 34b27f3cca1da47c576ae746bbf3a7f17de22916 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
#include <curses.h>

#include "screen.h"

WINDOW *screen_init(bool israw)
{
	WINDOW *screen = initscr();

	if (israw)
		raw();
	noecho();
	cbreak();
	nodelay(screen, TRUE);
	keypad(stdscr, TRUE);
	refresh();
	wrefresh(screen);

	return screen;
}

void screen_end(void)
{
	endwin();
}
4d'>patch) tree696fbffa8a7082f4c348a0244922ff4bace4594e parent90bcf1338193da4c87fb7492c716f225b907acf4 (diff)
raid5: fix to detect failure of register_shrinker
register_shrinker can fail after commit 1d3d4437eae1 ("vmscan: per-node deferred work"), we should detect the failure of it, otherwise we may fail to register shrinker after raid5 configuration was setup successfully. Signed-off-by: Chao Yu <yuchao0@huawei.com> Signed-off-by: Shaohua Li <shli@fb.com>
Diffstat