Lines Matching refs:handles
814 static struct sony_nc_handles *handles;
822 for (i = 0; i < ARRAY_SIZE(handles->cap); i++) {
824 handles->cap[i]);
835 handles = kzalloc(sizeof(*handles), GFP_KERNEL);
836 if (!handles)
839 for (i = 0; i < ARRAY_SIZE(handles->cap); i++) {
846 handles->cap[i] = result;
851 sysfs_attr_init(&handles->devattr.attr);
852 handles->devattr.attr.name = "handles";
853 handles->devattr.attr.mode = S_IRUGO;
854 handles->devattr.show = sony_nc_handles_show;
857 if (device_create_file(&pd->dev, &handles->devattr)) {
858 kfree(handles);
859 handles = NULL;
869 if (handles) {
871 device_remove_file(&pd->dev, &handles->devattr);
872 kfree(handles);
873 handles = NULL;
883 if (!handles || !handle)
887 if (handles->cap[i] == handle) {
1196 if (offset >= ARRAY_SIZE(handles->cap)) {
1201 handle = handles->cap[offset];
1203 /* list of handles known for generating events */
1298 if (!handles)
1301 /* setup found handles here */
1302 for (i = 0; i < ARRAY_SIZE(handles->cap); i++) {
1303 unsigned int handle = handles->cap[i];
1428 if (!handles)
1435 /* cleanup handles here */
1436 for (i = 0; i < ARRAY_SIZE(handles->cap); i++) {
1438 handle = handles->cap[i];
1500 /* finally cleanup the handles list */
1511 for (i = 0; i < ARRAY_SIZE(handles->cap); i++) {
1512 unsigned int handle = handles->cap[i];
1877 /* verify the kbd backlight presence, some of these handles are not used
3218 /* retrieve the available handles */