aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/staging/gpib/common (follow)
AgeCommit message (Collapse)AuthorFilesLines
2025-08-19staging: gpib: tidy-up commentsLuke Yang2-2/+2
Improve comment readability: - "//comment" -> "// comment" - Align comments vertically in columns - Enforce consistency between "// comments" and "/* comments */" Signed-off-by: Luke Yang <lukeyang.dev@gmail.com> Link: https://lore.kernel.org/r/aJ4ykOs_MmjnQdPa@luyang-thinkpadp1gen7.toromso.csb Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2025-07-29Merge tag 'staging-6.17-rc1' of ↵Linus Torvalds1-2/+2
git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging Pull staging updates from Greg KH: "Here is the "big" set of staging driver changes for 6.17-rc1. That's in quotes as it really isn't all that big of a set of changes this development cycle at all. Major things that stand out are: - gpib cleanups and tweaks with the majority of the big issues now taken care of. Odds are it will move out of staging/ in the next merge window if all goes well. - more constant cleanups and layer removals from the rtl8723bs driver. It's amazing how many layers deep they really are, all cleanups here are great to see - axis-fifo sysfs api removed and debugfs api added. The sysfs api didn't work at all so obviously no one was using it. Add the same information into debugfs as that's the proper place for it, and make it actually work. - Remaining changes is lots of small checkpatch cleanups, most of which seem to have come from a Debconf session where people were encouraged to submit their first kernel patch, a nice thing to see happen again. All of these have been in linux-next with no reported issues" * tag 'staging-6.17-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging: (71 commits) staging: rtl8723bs: remove redundant semicolon in basic_types.h staging: gpib: Add init response codes for new ni-usb-hs+ staging: rtl8723bs: DoIQK_8723B is empty staging: rtl8723bs: dm_CheckStatistics is empty staging: rtl8723bs: hw_var_port_switch is empty staging: rtl8723bs: _InitOtherVariable is empty staging: rtl8723bs: rtw_get_encrypt_decrypt_from_registrypriv is empty staging: rtl8723bs: rtl8723b_set_FwAoacRsvdPage_cmd is empty staging: rtl8723bs: CheckFwRsvdPageContent is empty staging: rtl8723bs: clean up redundant & parentheses staging: axis-fifo: add debugfs interface for dumping fifo registers staging: axis-fifo: remove sysfs interface staging: nvec: Fix incorrect null termination of battery manufacturer staging: gpib: fix typo staging: sm750fb: fix CamelCase variable naming staging: vme_user: fix spelling errors staging: rtl8723bs: remove unnecessary braces in rtl8723b_cmd staging: rtl8723bs: remove unnecessary commented code staging: rtl8723bs: add missing blank line after declaration staging: rtl8723bs: remove unnecessary comment separator lines ...
2025-07-10gpib: use file_inode()Al Viro1-1/+1
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
2025-07-09staging: gpib: Fix error code in board_type_ioctl()Harshit Mogalapalli1-1/+1
When copy_from_user() fails it return number of bytes it wasn't able to copy. So the correct return value when copy_from_user() fails is -EFAULT. Fixes: 9dde4559e939 ("staging: gpib: Add GPIB common core driver") Signed-off-by: Harshit Mogalapalli <harshit.m.mogalapalli@oracle.com> Link: https://lore.kernel.org/r/20250703064633.1955893-1-harshit.m.mogalapalli@oracle.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2025-06-30staging: gpib: fix unset padding field copy back to userspaceColin Ian King1-1/+1
The introduction of a padding field in the gpib_board_info_ioctl is showing up as initialized data on the stack frame being copyied back to userspace in function board_info_ioctl. The simplest fix is to initialize the entire struct to zero to ensure all unassigned padding fields are zero'd before being copied back to userspace. Signed-off-by: Colin Ian King <colin.i.king@gmail.com> Fixes: 9dde4559e939 ("staging: gpib: Add GPIB common core driver") Signed-off-by: Dan Carpenter <dan.carpenter@linaro.org> Link: https://lore.kernel.org/r/20250623220958.280424-1-colin.i.king@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2025-06-08treewide, timers: Rename from_timer() to timer_container_of()Ingo Molnar2-3/+4
Move this API to the canonical timer_*() namespace. [ tglx: Redone against pre rc1 ] Signed-off-by: Ingo Molnar <mingo@kernel.org> Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Link: https://lore.kernel.org/all/aB2X0jCKQO56WdMt@gmail.com
2025-06-06Merge tag 'staging-6.16-rc1' of ↵Linus Torvalds3-178/+211
git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging Pull staging driver updates from Greg KH: "Here is the "big" set of staging driver changes for 6.16-rc1. Included in here are: - gpib driver cleanups and updates. This subsystem is _almost_ ready to be merged into the main portion of the kernel tree. Hopefully should happen in the next kernel merge cycle if all goes well. - sm750fb driver cleanups - rtl8723bs driver cleanups - other small driver cleanups for coding style issues All of these have been in for over 2 weeks with no reported issues" * tag 'staging-6.16-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging: (203 commits) staging: rtl8723bs: remove unnecessary braces for single statement blocks staging: rtl8723bs: Removed multiple blank lines of rtw_pwrctrl.c staging: sm750fb: rename `hw_sm750le_setBLANK` staging: sm750fb: rename `hw_sm750_setBLANK` staging: sm750fb: rename `hw_sm750_setColReg` staging: sm750fb: rename `hw_sm750_crtc_setMode` staging: sm750fb: rename `hw_sm750_crtc_checkMode` staging: sm750fb: rename `hw_sm750_output_setMode` staging: sm750fb: rename `hw_sm750le_deWait` staging: sm750fb: rename `hw_sm750_deWait` staging: sm750fb: rename `hw_sm750_initAccel` staging: gpib: switch to kmalloc(sizeof(*status)) staging: gpib: Fix secondary address restriction staging: gpib: Fix uapi include header guard name staging: gpib: Avoid unused variable warning staging: gpib: Declare driver entry points static staging: gpib: Fix PCMCIA config identifier staging: gpib: Avoid unused variable warnings staging: gpib: Fix lpvo request_system_control staging: sm750fb: rename sm750_hw_cursor_setData2 ...
2025-05-21staging: gpib: switch to kmalloc(sizeof(*status))Andreas Kleinbichler1-1/+1
Fix checkpatch warning: Prefer kmalloc(sizeof(*status)...) over kmalloc(sizeof(struct gpib_status_byte)...) Signed-off-by: Andreas Kleinbichler <andi.kleinbichler@gmail.com> Link: https://lore.kernel.org/r/aCdY-OgvoTUjcIeF@andreas-VirtualBox Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2025-05-08treewide, timers: Rename destroy_timer_on_stack() as timer_destroy_on_stack()Ingo Molnar1-1/+1
Move this API to the canonical timer_*() namespace. Signed-off-by: Ingo Molnar <mingo@kernel.org> Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Link: https://lore.kernel.org/all/20250507175338.672442-10-mingo@kernel.org
2025-04-18staging: gpib: Add return value to request_controlDave Penkler2-7/+14
A number of drivers are unable to release control due to hardware or software limitations. As request_system_control was defined as void, no error could be signalled. This patch changes the prototype of request_system_control to int and adds the appropriate checking and returns. In the case that a board cannot release control EINVAL is returned. If a driver does not implement request_system_control EPERM is returned. Signed-off-by: Dave Penkler <dpenkler@gmail.com> Link: https://lore.kernel.org/r/20250418133537.22491-1-dpenkler@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2025-04-17staging: gpib: common: struct gpib_interfaceMichael Rubin1-2/+2
Using Linux code style for struct gpib_interface. Adhering to Linux code style. Reported by checkpatch.pl In general, a pointer, or a struct that has elements that can reasonably be directly accessed should never be a typedef. Signed-off-by: Michael Rubin <matchstick@neverthere.org> Link: https://lore.kernel.org/r/20250417003246.84445-7-matchstick@neverthere.org Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2025-04-17staging: gpib: gpib_os: u8 over uint8_tMichael Rubin1-4/+4
Reported by checkpatch.pl. CHECK: Prefer kernel type 'u8' over 'uint8_t' Signed-off-by: Michael Rubin <matchstick@neverthere.org> Link: https://lore.kernel.org/r/20250417004533.86765-7-matchstick@neverthere.org Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2025-04-15staging: gpib: common: fixes multiline comments stylePaul Retourné2-25/+41
Fixes the style of multiline comments to comply with the linux kernel coding style. Signed-off-by: Paul Retourné <paul.retourne@orange.fr> Link: https://lore.kernel.org/r/2ffeae1761ba77526e6aa7188f07d25a2f9a1950.1744438358.git.paul.retourne@orange.fr Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2025-04-15staging: gpib: local_ppoll_mode_ioctl_t now shortMichael Rubin1-2/+2
Using Linux code style to replace typedef local_ppoll_mode_ioctl_t with type short. Adhering to Linux code style. Reported by checkpatch.pl WARNING: do not add new typedefs Signed-off-by: Michael Rubin <matchstick@neverthere.org> Link: https://lore.kernel.org/r/20250409055903.321438-22-matchstick@neverthere.org Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2025-04-15staging: gpib: autospoll_ioctl_t now shortMichael Rubin1-1/+1
Using Linux code style to replace typedef autospoll_ioctl_t with type short. Adhering to Linux code style. Reported by checkpatch.pl WARNING: do not add new typedefs Signed-off-by: Michael Rubin <matchstick@neverthere.org> Link: https://lore.kernel.org/r/20250409055903.321438-21-matchstick@neverthere.org Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2025-04-15staging: gpib: t1_delay_ioctl_t now unsigned intMichael Rubin1-1/+1
Using Linux code style to replace typedef t1_delay_ioctl_t with type unsigned int. Adhering to Linux code style. Reported by checkpatch.pl WARNING: do not add new typedefs Signed-off-by: Michael Rubin <matchstick@neverthere.org> Link: https://lore.kernel.org/r/20250409055903.321438-20-matchstick@neverthere.org Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2025-04-15staging: gpib: rsc_ioctl_t now intMichael Rubin1-1/+1
Using Linux code style to replace typedef rsc_ioctl_t with type int. Adhering to Linux code style. Reported by checkpatch.pl WARNING: do not add new typedefs Signed-off-by: Michael Rubin <matchstick@neverthere.org> Link: https://lore.kernel.org/r/20250409055903.321438-19-matchstick@neverthere.org Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2025-04-15staging: gpib: event_ioctl_t now shortMichael Rubin1-1/+1
Using Linux code style to replace typedef event_ioctl_t with type short. Adhering to Linux code style. Reported by checkpatch.pl WARNING: do not add new typedefs Signed-off-by: Michael Rubin <matchstick@neverthere.org> Link: https://lore.kernel.org/r/20250409055903.321438-18-matchstick@neverthere.org Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2025-04-15staging: gpib: Using struct gpib_request_service2Michael Rubin1-2/+2
Using Linux code style for 'struct gpib_request_service2' to remove typedef. Adhering to Linux code style. Reported by checkpatch.pl In general, a pointer, or a struct that has elements that can reasonably be directly accessed should never be a typedef. Signed-off-by: Michael Rubin <matchstick@neverthere.org> Link: https://lore.kernel.org/r/20250409055903.321438-17-matchstick@neverthere.org Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2025-04-15staging: gpib: Using gpib_select_device_path_ioctlMichael Rubin1-3/+4
Using Linux code style for 'struct gpib_select_device_path_ioctl' to remove typedef. Adhering to Linux code style. Reported by checkpatch.pl In general, a pointer, or a struct that has elements that can reasonably be directly accessed should never be a typedef. Signed-off-by: Michael Rubin <matchstick@neverthere.org> Link: https://lore.kernel.org/r/20250409055903.321438-16-matchstick@neverthere.org Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2025-04-15staging: gpib: Using struct gpib_sad_ioctlMichael Rubin1-1/+1
Using Linux code style for 'struct gpib_sad_ioctl' to remove typedef. Adhering to Linux code style. Reported by checkpatch.pl In general, a pointer, or a struct that has elements that can reasonably be directly accessed should never be a typedef. Signed-off-by: Michael Rubin <matchstick@neverthere.org> Link: https://lore.kernel.org/r/20250409055903.321438-15-matchstick@neverthere.org Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2025-04-15staging: gpib: Using struct gpib_pad_ioctlMichael Rubin1-1/+1
Using Linux code style for 'struct gpib_pad_ioctl' to remove typedef. Adhering to Linux code style. Reported by checkpatch.pl In general, a pointer, or a struct that has elements that can reasonably be directly accessed should never be a typedef. Signed-off-by: Michael Rubin <matchstick@neverthere.org> Link: https://lore.kernel.org/r/20250409055903.321438-14-matchstick@neverthere.org Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2025-04-15staging: gpib: Using struct gpib_ppoll_config_ioctl`Michael Rubin1-1/+1
Using Linux code style for 'struct gpib_ppoll_config_ioctl' to remove typedef. Adhering to Linux code style. Reported by checkpatch.pl In general, a pointer, or a struct that has elements that can reasonably be directly accessed should never be a typedef. Signed-off-by: Michael Rubin <matchstick@neverthere.org> Link: https://lore.kernel.org/r/20250409055903.321438-13-matchstick@neverthere.org Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2025-04-15staging: gpib: Using struct gpib_select_pci_ioctlMichael Rubin1-1/+1
Using Linux code style for 'struct gpib_select_pci_ioctl' to remove typedef. Adhering to Linux code style. Reported by checkpatch.pl In general, a pointer, or a struct that has elements that can reasonably be directly accessed should never be a typedef. Signed-off-by: Michael Rubin <matchstick@neverthere.org> Link: https://lore.kernel.org/r/20250409055903.321438-12-matchstick@neverthere.org Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2025-04-15staging: gpib: Using struct gpib_board_info_ioctlMichael Rubin1-1/+1
Using Linux code style for 'struct gpib_board_info_ioctl' to remove typedef. Adhering to Linux code style. Reported by checkpatch.pl In general, a pointer, or a struct that has elements that can reasonably be directly accessed should never be a typedef. Signed-off-by: Michael Rubin <matchstick@neverthere.org> Link: https://lore.kernel.org/r/20250409055903.321438-11-matchstick@neverthere.org Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2025-04-15staging: gpib: Using struct gpib_spoll_bytes_ioctlMichael Rubin1-1/+1
Using Linux code style for 'struct gpib_spoll_bytes_ioctl' to remove typedef. Adhering to Linux code style. Reported by checkpatch.pl In general, a pointer, or a struct that has elements that can reasonably be directly accessed should never be a typedef. Signed-off-by: Michael Rubin <matchstick@neverthere.org> Link: https://lore.kernel.org/r/20250409055903.321438-10-matchstick@neverthere.org Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2025-04-15staging: gpib: Using struct gpib_online_ioctlMichael Rubin1-1/+1
Using Linux code style for 'struct gpib_online_ioctl' to remove typedef. Adhering to Linux code style. Reported by checkpatch.pl In general, a pointer, or a struct that has elements that can reasonably be directly accessed should never be a typedef. Signed-off-by: Michael Rubin <matchstick@neverthere.org> Link: https://lore.kernel.org/r/20250409055903.321438-9-matchstick@neverthere.org Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2025-04-15staging: gpib: Using struct gpib_wait_ioctlMichael Rubin1-1/+1
Using Linux code style for 'struct gpib_wait_ioctl' to remove typedef. Adhering to Linux code style. Reported by checkpatch.pl In general, a pointer, or a struct that has elements that can reasonably be directly accessed should never be a typedef. Signed-off-by: Michael Rubin <matchstick@neverthere.org> Link: https://lore.kernel.org/r/20250409055903.321438-8-matchstick@neverthere.org Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2025-04-15staging: gpib: Using struct gpib_eos_ioctlMichael Rubin1-1/+1
Using Linux code style for 'struct gpib_eos_ioctl' to remove typedef. Adhering to Linux code style. Reported by checkpatch.pl In general, a pointer, or a struct that has elements that can reasonably be directly accessed should never be a typedef. Signed-off-by: Michael Rubin <matchstick@neverthere.org> Link: https://lore.kernel.org/r/20250409055903.321438-7-matchstick@neverthere.org Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2025-04-15staging: gpib: Using struct gpib_serial_poll_ioctlMichael Rubin1-1/+1
Using Linux code style for 'struct gpib_serial_poll_ioctl' to remove typedef. Adhering to Linux code style. Reported by checkpatch.pl In general, a pointer, or a struct that has elements that can reasonably be directly accessed should never be a typedef. Signed-off-by: Michael Rubin <matchstick@neverthere.org> Link: https://lore.kernel.org/r/20250409055903.321438-6-matchstick@neverthere.org Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2025-04-15staging: gpib: Using struct gpib_close_dev_ioctlMichael Rubin1-1/+1
Using Linux code style for 'struct gpib_close_dev_ioctl' to remove typedef. Adhering to Linux code style. Reported by checkpatch.pl In general, a pointer, or a struct that has elements that can reasonably be directly accessed should never be a typedef. Signed-off-by: Michael Rubin <matchstick@neverthere.org> Link: https://lore.kernel.org/r/20250409055903.321438-5-matchstick@neverthere.org Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2025-04-15staging: gpib: Using struct gpib_open_dev_ioctlMichael Rubin1-1/+1
Using Linux code style for 'struct gpib_open_dev_ioctl' to remove typedef. Adhering to Linux code style. Reported by checkpatch.pl In general, a pointer, or a struct that has elements that can reasonably be directly accessed should never be a typedef. Signed-off-by: Michael Rubin <matchstick@neverthere.org> Link: https://lore.kernel.org/r/20250409055903.321438-4-matchstick@neverthere.org Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2025-04-15staging: gpib: Using struct gpib_read_write_ioctlMichael Rubin1-3/+3
Using Linux code style for 'struct gpib_read_write_ioctl' to remove typedef. Adhering to Linux code style. Reported by checkpatch.pl In general, a pointer, or a struct that has elements that can reasonably be directly accessed should never be a typedef. Signed-off-by: Michael Rubin <matchstick@neverthere.org> Link: https://lore.kernel.org/r/20250409055903.321438-3-matchstick@neverthere.org Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2025-04-15staging: gpib: Using struct gpib_board_type_ioctlMichael Rubin1-2/+3
Using Linux code style for 'struct gpib_board_type_ioctl' to remove typedef. Adhering to Linux code style. Reported by checkpatch.pl In general, a pointer, or a struct that has elements that can reasonably be directly accessed should never be a typedef. Signed-off-by: Michael Rubin <matchstick@neverthere.org> Link: https://lore.kernel.org/r/20250409055903.321438-2-matchstick@neverthere.org Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2025-04-15staging: gpib: ibsys: u8 over uint8_tMichael Rubin2-9/+9
Reported by checkpatch.pl. CHECK: Prefer kernel type 'u8' over 'uint8_t' Signed-off-by: Michael Rubin <matchstick@neverthere.org> Link: https://lore.kernel.org/r/20250409180953.398686-3-matchstick@neverthere.org Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2025-04-15staging: gpib: Remove typedef gpib_file_private_tMichael Rubin1-30/+31
Removing gpib_file_private_t to adhere to Linux code style. Reported by checkpatch.pl In general, a pointer, or a struct that has elements that can reasonably be directly accessed should never be a typedef. Signed-off-by: Michael Rubin <matchstick@neverthere.org> Link: https://lore.kernel.org/r/20250408232535.187528-8-matchstick@neverthere.org Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2025-04-15staging: gpib: Removing typedef gpib_descriptor_tMichael Rubin2-16/+16
Removing gpib_descriptor_t to adhere to Linux code style. Reported by checkpatch.pl In general, a pointer, or a struct that has elements that can reasonably be directly accessed should never be a typedef. Signed-off-by: Michael Rubin <matchstick@neverthere.org> Link: https://lore.kernel.org/r/20250408232535.187528-7-matchstick@neverthere.org Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2025-04-15staging: gpib: Removing typedef of status_byteMichael Rubin1-4/+4
Replacing typedef of status_byte_t with struct gpib_status_byte to adhere to Linux coding style. Reported by checkpatch.pl In general, a pointer, or a struct that has elements that can reasonably be directly accessed should never be a typedef. Signed-off-by: Michael Rubin <matchstick@neverthere.org> Link: https://lore.kernel.org/r/20250408232535.187528-6-matchstick@neverthere.org Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2025-04-15staging: gpib: Removing typedef gpib_status_queueMichael Rubin3-24/+27
Removing gpib_status_queue_t to adhere to Linux code style. Reported by checkpatch.pl In general, a pointer, or a struct that has elements that can reasonably be directly accessed should never be a typedef. Signed-off-by: Michael Rubin <matchstick@neverthere.org> Link: https://lore.kernel.org/r/20250408232535.187528-5-matchstick@neverthere.org Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2025-04-15staging: gpib: Removing gpib_event_t typedefMichael Rubin1-4/+4
Removing gpib_event_t to adhere to Linux code style. Reported by checkpatch.pl In general, a pointer, or a struct that has elements that can reasonably be directly accessed should never be a typedef. Signed-off-by: Michael Rubin <matchstick@neverthere.org> Link: https://lore.kernel.org/r/20250408232535.187528-4-matchstick@neverthere.org Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2025-04-15staging: gpib: Removing gpib_interface_list_tMichael Rubin1-5/+5
Removing gpib_interface_list_t to adhere to Linux code style. Reported by checkpatch.pl In general, a pointer, or a struct that has elements that can reasonably be directly accessed should never be a typedef. Signed-off-by: Michael Rubin <matchstick@neverthere.org> Link: https://lore.kernel.org/r/20250408232535.187528-3-matchstick@neverthere.org Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2025-04-15staging: gpib: Removing typedef gpib_event_queueMichael Rubin1-5/+5
Removing gpib_event_queue_t to adhere to Linux code style. Reported by checkpatch.pl In general, a pointer, or a struct that has elements that can reasonably be directly accessed should never be a typedef. Signed-off-by: Michael Rubin <matchstick@neverthere.org> Link: https://lore.kernel.org/r/20250408232535.187528-2-matchstick@neverthere.org Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2025-04-15staging: gpib: common: struct gpib_board_configMichael Rubin1-14/+14
Using Linux code style for struct gpib_board_config Adhering to Linux code style. Reported by checkpatch.pl In general, a pointer, or a struct that has elements that can reasonably be directly accessed should never be a typedef. Signed-off-by: Michael Rubin <matchstick@neverthere.org> Link: https://lore.kernel.org/r/20250408223659.187109-7-matchstick@neverthere.org Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2025-04-15staging: gpib: common: lines exceeded 100 columnsMichael Rubin1-6/+10
Adhere to Linux kernel coding style. CHECK: line length exceeds 100 columns Reported by checkpatch Signed-off-by: Michael Rubin <matchstick@neverthere.org> Link: https://lore.kernel.org/r/20250408222040.186881-5-matchstick@neverthere.org Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2025-04-15staging: gpib: Correct CamelCase for EVENT enumsMichael Rubin1-3/+3
Adhere to Linux kernel coding style. Reported by checkpatch CHECK: Avoid CamelCase: <EventNone> CHECK: Avoid CamelCase: <EventDevTrg> CHECK: Avoid CamelCase: <EventDevClr> CHECK: Avoid CamelCase: <EventIfc> Signed-off-by: Michael Rubin <matchstick@neverthere.org> Link: https://lore.kernel.org/r/20250408222040.186881-2-matchstick@neverthere.org Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2025-04-05treewide: Switch/rename to timer_delete[_sync]()Thomas Gleixner2-3/+3
timer_delete[_sync]() replaces del_timer[_sync](). Convert the whole tree over and remove the historical wrapper inlines. Conversion was done with coccinelle plus manual fixups where necessary. Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: Ingo Molnar <mingo@kernel.org>
2025-03-20staging: gpib: change return type of t1_delay function to report errorsRodrigo Gobbi1-1/+4
The current code returns "unsigned int" and it doesn't handle errors correctly if it happens during ioctl call for t1 delay configuration. The ni_usb_t1_delay(), from NI, is the only function returning -1 at this point. The caller, t1_delay_ioctl(), doesn't check for errors and sets board->t1_nano_sec to -1 and returns success. The board->t1_nano_sec value is also used in ni_usb_setup_t1_delay() besides the ioctl call and a value of -1 is treated as being above 1100ns. It may or may not have a noticeable effect, but it's obviously not right considering the content of ni_usb_setup_t1_delay(). Typical delays are in the 200-2000 range, but definitely not more than INT_MAX so we can fix this code by changing the return type to int and adding a check for errors. While we're at it, lets change the error code in ni_usb_t1_delay() from -1 and instead propagate the error from ni_usb_write_registers(). Fixes: 4e127de14fa7 ("staging: gpib: Add National Instruments USB GPIB driver") Signed-off-by: Rodrigo Gobbi <rodrigo.gobbi.7@gmail.com> Link: https://lore.kernel.org/r/20250225014811.77995-1-rodrigo.gobbi.7@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2025-03-20staging: gpib: common: struct gpib_boardMichael Rubin3-130/+130
Using Linux code style for struct gpib_board. Adhering to Linux code style. In general, a pointer, or a struct that has elements that can reasonably be directly accessed should never be a typedef. Signed-off-by: Michael Rubin <matchstick@neverthere.org> Acked-By: Dave Penkler <dpenkler@gmail.com> Link: https://lore.kernel.org/r/20250319215924.19387-7-matchstick@neverthere.org Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2025-03-20staging: gpib: Correct CamelCase for VALID enumsMichael Rubin1-2/+2
Adhere to Linux kernel coding style. Reported by checkpatch CHECK: Avoid CamelCase Signed-off-by: Michael Rubin <matchstick@neverthere.org> Acked-By: Dave Penkler <dpenkler@gmail.com> Link: https://lore.kernel.org/r/20250319211827.9854-3-matchstick@neverthere.org Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2025-03-20staging: gpib: Correct CamelCase for BUS constantsMichael Rubin1-2/+2
Adhere to Linux kernel coding style and remove duplicate enums. Reported by checkpatch CHECK: Avoid CamelCase Signed-off-by: Michael Rubin <matchstick@neverthere.org> Acked-By: Dave Penkler <dpenkler@gmail.com> Link: https://lore.kernel.org/r/20250319211827.9854-2-matchstick@neverthere.org Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>