Lines Matching refs:bdev
54 struct buttons_dev *bdev = input_get_drvdata(input); in handle_buttons() local
60 for (i = 0; i < ARRAY_SIZE(bdev->keymap); i++) { in handle_buttons()
62 if (++bdev->count[i] == BUTTONS_COUNT_THRESHOLD) { in handle_buttons()
64 input_report_key(input, bdev->keymap[i], 1); in handle_buttons()
68 if (bdev->count[i] >= BUTTONS_COUNT_THRESHOLD) { in handle_buttons()
70 input_report_key(input, bdev->keymap[i], 0); in handle_buttons()
73 bdev->count[i] = 0; in handle_buttons()
80 struct buttons_dev *bdev; in sgi_buttons_probe() local
84 bdev = devm_kzalloc(&pdev->dev, sizeof(*bdev), GFP_KERNEL); in sgi_buttons_probe()
85 if (!bdev) in sgi_buttons_probe()
92 memcpy(bdev->keymap, sgi_map, sizeof(bdev->keymap)); in sgi_buttons_probe()
94 input_set_drvdata(input, bdev); in sgi_buttons_probe()
100 input->keycode = bdev->keymap; in sgi_buttons_probe()
101 input->keycodemax = ARRAY_SIZE(bdev->keymap); in sgi_buttons_probe()
107 __set_bit(bdev->keymap[i], input->keybit); in sgi_buttons_probe()