sphinx.addnodesdocument)}( rawsourcechildren]( translations LanguagesNode)}(hhh](h pending_xref)}(hhh]docutils.nodesTextChinese (Simplified)}parenthsba attributes}(ids]classes]names]dupnames]backrefs] refdomainstdreftypedoc reftarget,/translations/zh_CN/driver-api/miscellaneousmodnameN classnameN refexplicitutagnamehhh ubh)}(hhh]hChinese (Traditional)}hh2sbah}(h]h ]h"]h$]h&] refdomainh)reftypeh+ reftarget,/translations/zh_TW/driver-api/miscellaneousmodnameN classnameN refexplicituh1hhh ubh)}(hhh]hItalian}hhFsbah}(h]h ]h"]h$]h&] refdomainh)reftypeh+ reftarget,/translations/it_IT/driver-api/miscellaneousmodnameN classnameN refexplicituh1hhh ubh)}(hhh]hJapanese}hhZsbah}(h]h ]h"]h$]h&] refdomainh)reftypeh+ reftarget,/translations/ja_JP/driver-api/miscellaneousmodnameN classnameN refexplicituh1hhh ubh)}(hhh]hKorean}hhnsbah}(h]h ]h"]h$]h&] refdomainh)reftypeh+ reftarget,/translations/ko_KR/driver-api/miscellaneousmodnameN classnameN refexplicituh1hhh ubh)}(hhh]hPortuguese (Brazilian)}hhsbah}(h]h ]h"]h$]h&] refdomainh)reftypeh+ reftarget,/translations/pt_BR/driver-api/miscellaneousmodnameN classnameN refexplicituh1hhh ubh)}(hhh]hSpanish}hhsbah}(h]h ]h"]h$]h&] refdomainh)reftypeh+ reftarget,/translations/sp_SP/driver-api/miscellaneousmodnameN classnameN refexplicituh1hhh ubeh}(h]h ]h"]h$]h&]current_languageEnglishuh1h hh _documenthsourceNlineNubhsection)}(hhh](htitle)}(hParallel Port Devicesh]hParallel Port Devices}(hhhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhhhF/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous.rsthKubhindex)}(hhh]h}(h]h ]h"]h$]h&]entries](single!parport_register_driver (C macro)c.parport_register_driverhNtauh1hhhhhhNhNubhdesc)}(hhh](hdesc_signature)}(hparport_register_driverh]hdesc_signature_line)}(hparport_register_driverh]h desc_name)}(hparport_register_driverh]h desc_sig_name)}(hhh]hparport_register_driver}(hhhhhNhNubah}(h]h ]nah"]h$]h&]uh1hhhubah}(h]h ](sig-namedescnameeh"]h$]h&] xml:spacepreserveuh1hhhhhh_/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:4: ./include/linux/parport.hhM&ubah}(h]h ]h"]h$]h&]j j  add_permalinkuh1hsphinx_line_type declaratorhhhhhj hM&ubah}(h]hah ](sig sig-objecteh"]h$]h&] is_multiline _toc_parts) _toc_namehuh1hhj hM&hhhhubh desc_content)}(hhh]h}(h]h ]h"]h$]h&]uh1j"hhhhhj hM&ubeh}(h]h ](cmacroeh"]h$]h&]domainj0objtypej1desctypej1noindex noindexentrynocontentsentryuh1hhhhhhNhNubh paragraph)}(h$``parport_register_driver (driver)``h]hliteral)}(hj?h]h parport_register_driver (driver)}(hjChhhNhNubah}(h]h ]h"]h$]h&]uh1jAhj=ubah}(h]h ]h"]h$]h&]uh1j;h_/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:4: ./include/linux/parport.hhM(hhhhubh block_quote)}(h'register a parallel port device driver h]j<)}(h®ister a parallel port device driverh]h®ister a parallel port device driver}(hj]hhhNhNubah}(h]h ]h"]h$]h&]uh1j;h_/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:4: ./include/linux/parport.hhM&hjYubah}(h]h ]h"]h$]h&]uh1jWhjkhM&hhhhubh container)}(hXj**Parameters** ``driver`` structure describing the driver **Description** This can be called by a parallel port device driver in order to receive notifications about ports being found in the system, as well as ports no longer available. The **driver** structure is allocated by the caller and must not be deallocated until after calling parport_unregister_driver(). If using the non device model: The driver's attach() function may block. The port that attach() is given will be valid for the duration of the callback, but if the driver wants to take a copy of the pointer it must call parport_get_port() to do so. Calling parport_register_device() on that port will do this for you. The driver's detach() function may block. The port that detach() is given will be valid for the duration of the callback, but if the driver wants to take a copy of the pointer it must call parport_get_port() to do so. Returns 0 on success. The non device model will always succeeds. but the new device model can fail and will return the error code.h](j<)}(h**Parameters**h]hstrong)}(hjzh]h Parameters}(hj~hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjxubah}(h]h ]h"]h$]h&]uh1j;h_/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:4: ./include/linux/parport.hhM*hjtubhdefinition_list)}(hhh]hdefinition_list_item)}(h+``driver`` structure describing the driver h](hterm)}(h ``driver``h]jB)}(hjh]hdriver}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhjubah}(h]h ]h"]h$]h&]uh1jh_/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:4: ./include/linux/parport.hhM'hjubh definition)}(hhh]j<)}(hstructure describing the driverh]hstructure describing the driver}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hjhM'hjubah}(h]h ]h"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]uh1jhjhM'hjubah}(h]h ]h"]h$]h&]uh1jhjtubj<)}(h**Description**h]j})}(hjh]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjubah}(h]h ]h"]h$]h&]uh1j;h_/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:4: ./include/linux/parport.hhM)hjtubjX)}(hXThis can be called by a parallel port device driver in order to receive notifications about ports being found in the system, as well as ports no longer available. The **driver** structure is allocated by the caller and must not be deallocated until after calling parport_unregister_driver(). If using the non device model: The driver's attach() function may block. The port that attach() is given will be valid for the duration of the callback, but if the driver wants to take a copy of the pointer it must call parport_get_port() to do so. Calling parport_register_device() on that port will do this for you. The driver's detach() function may block. The port that detach() is given will be valid for the duration of the callback, but if the driver wants to take a copy of the pointer it must call parport_get_port() to do so. Returns 0 on success. The non device model will always succeeds. but the new device model can fail and will return the error code.h](j<)}(hThis can be called by a parallel port device driver in order to receive notifications about ports being found in the system, as well as ports no longer available.h]hThis can be called by a parallel port device driver in order to receive notifications about ports being found in the system, as well as ports no longer available.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j;h_/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:4: ./include/linux/parport.hhM(hjubj<)}(hThe **driver** structure is allocated by the caller and must not be deallocated until after calling parport_unregister_driver().h](hThe }(hjhhhNhNubj})}(h **driver**h]hdriver}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjubhr structure is allocated by the caller and must not be deallocated until after calling parport_unregister_driver().}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1j;h_/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:4: ./include/linux/parport.hhM,hjubj<)}(hX?If using the non device model: The driver's attach() function may block. The port that attach() is given will be valid for the duration of the callback, but if the driver wants to take a copy of the pointer it must call parport_get_port() to do so. Calling parport_register_device() on that port will do this for you.h]hXAIf using the non device model: The driver’s attach() function may block. The port that attach() is given will be valid for the duration of the callback, but if the driver wants to take a copy of the pointer it must call parport_get_port() to do so. Calling parport_register_device() on that port will do this for you.}(hj(hhhNhNubah}(h]h ]h"]h$]h&]uh1j;h_/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:4: ./include/linux/parport.hhM/hjubj<)}(hThe driver's detach() function may block. The port that detach() is given will be valid for the duration of the callback, but if the driver wants to take a copy of the pointer it must call parport_get_port() to do so.h]hThe driver’s detach() function may block. The port that detach() is given will be valid for the duration of the callback, but if the driver wants to take a copy of the pointer it must call parport_get_port() to do so.}(hj7hhhNhNubah}(h]h ]h"]h$]h&]uh1j;h_/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:4: ./include/linux/parport.hhM6hjubj<)}(hReturns 0 on success. The non device model will always succeeds. but the new device model can fail and will return the error code.h]hReturns 0 on success. The non device model will always succeeds. but the new device model can fail and will return the error code.}(hjFhhhNhNubah}(h]h ]h"]h$]h&]uh1j;h_/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:4: ./include/linux/parport.hhM<hjubeh}(h]h ]h"]h$]h&]uh1jWhjhM(hjtubeh}(h]h ] kernelindentah"]h$]h&]uh1jrhhhhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](h،module_parport_driver (C macro)c.module_parport_driverhNtauh1hhhhhhNhNubh)}(hhh](h)}(hmodule_parport_driverh]h)}(hmodule_parport_driverh]h)}(hmodule_parport_driverh]h)}(hjuh]hmodule_parport_driver}(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj{ubah}(h]h ](jjeh"]h$]h&]j j uh1hhjwhhh_/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:4: ./include/linux/parport.hhMGubah}(h]h ]h"]h$]h&]j j juh1hjjhjshhhjhMGubah}(h]jnah ](jjeh"]h$]h&]jj )j!huh1hhjhMGhjphhubj#)}(hhh]h}(h]h ]h"]h$]h&]uh1j"hjphhhjhMGubeh}(h]h ](j0macroeh"]h$]h&]j5j0j6jj7jj8j9j:uh1hhhhhhNhNubj<)}(h,``module_parport_driver (__parport_driver)``h]jB)}(hjh]h(module_parport_driver (__parport_driver)}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhjubah}(h]h ]h"]h$]h&]uh1j;h_/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:4: ./include/linux/parport.hhMIhhhhubjX)}(h6Helper macro for registering a modular parport driver h]j<)}(h5Helper macro for registering a modular parport driverh]h5Helper macro for registering a modular parport driver}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j;h_/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:4: ./include/linux/parport.hhMGhjubah}(h]h ]h"]h$]h&]uh1jWhjhMGhhhhubjs)}(hX=**Parameters** ``__parport_driver`` struct parport_driver to be used **Description** Helper macro for parport drivers which do not do anything special in module init and exit. This eliminates a lot of boilerplate. Each module may only use this macro once, and calling it replaces module_init() and module_exit().h](j<)}(h**Parameters**h]j})}(hjh]h Parameters}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjubah}(h]h ]h"]h$]h&]uh1j;h_/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:4: ./include/linux/parport.hhMKhjubj)}(hhh]j)}(h6``__parport_driver`` struct parport_driver to be used h](j)}(h``__parport_driver``h]jB)}(hjh]h__parport_driver}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhjubah}(h]h ]h"]h$]h&]uh1jh_/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:4: ./include/linux/parport.hhMHhjubj)}(hhh]j<)}(h struct parport_driver to be usedh]h struct parport_driver to be used}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hjhMHhjubah}(h]h ]h"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]uh1jhjhMHhjubah}(h]h ]h"]h$]h&]uh1jhjubj<)}(h**Description**h]j})}(hj@h]h Description}(hjBhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj>ubah}(h]h ]h"]h$]h&]uh1j;h_/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:4: ./include/linux/parport.hhMJhjubj<)}(hHelper macro for parport drivers which do not do anything special in module init and exit. This eliminates a lot of boilerplate. Each module may only use this macro once, and calling it replaces module_init() and module_exit().h]hHelper macro for parport drivers which do not do anything special in module init and exit. This eliminates a lot of boilerplate. Each module may only use this macro once, and calling it replaces module_init() and module_exit().}(hjVhhhNhNubah}(h]h ]h"]h$]h&]uh1j;h_/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:4: ./include/linux/parport.hhMIhjubeh}(h]h ] kernelindentah"]h$]h&]uh1jrhhhhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](h،parport_yield (C function)c.parport_yieldhNtauh1hhhhhhNhNubh)}(hhh](h)}(h)int parport_yield (struct pardevice *dev)h]h)}(h(int parport_yield(struct pardevice *dev)h](hdesc_sig_keyword_type)}(hinth]hint}(hjhhhNhNubah}(h]h ]ktah"]h$]h&]uh1jhjhhh_/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:4: ./include/linux/parport.hhMubhdesc_sig_space)}(h h]h }(hjhhhNhNubah}(h]h ]wah"]h$]h&]uh1jhjhhhjhMubh)}(h parport_yieldh]h)}(h parport_yieldh]h parport_yield}(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubah}(h]h ](jjeh"]h$]h&]j j uh1hhjhhhjhMubhdesc_parameterlist)}(h(struct pardevice *dev)h]hdesc_parameter)}(hstruct pardevice *devh](hdesc_sig_keyword)}(hstructh]hstruct}(hjhhhNhNubah}(h]h ]kah"]h$]h&]uh1jhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubh)}(hhh]h)}(h pardeviceh]h pardevice}(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubah}(h]h ]h"]h$]h&] refdomainj0reftype identifier reftargetjmodnameN classnameN c:parent_keysphinx.domains.c LookupKey)}data]j  ASTIdentifier)}jjsbc.parport_yieldasbuh1hhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubhdesc_sig_punctuation)}(h*h]h*}(hj&hhhNhNubah}(h]h ]pah"]h$]h&]uh1j$hjubh)}(hdevh]hdev}(hj5hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubeh}(h]h ]h"]h$]h&]noemphj j uh1jhjubah}(h]h ]h"]h$]h&]j j uh1jhjhhhjhMubeh}(h]h ]h"]h$]h&]j j juh1hjjhj}hhhjhMubah}(h]jxah ](jjeh"]h$]h&]jj )j!huh1hhjhMhjzhhubj#)}(hhh]j<)}(h&relinquish a parallel port temporarilyh]h&relinquish a parallel port temporarily}(hj_hhhNhNubah}(h]h ]h"]h$]h&]uh1j;h_/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:4: ./include/linux/parport.hhMhj\hhubah}(h]h ]h"]h$]h&]uh1j"hjzhhhjhMubeh}(h]h ](j0functioneh"]h$]h&]j5j0j6jwj7jwj8j9j:uh1hhhhhhNhNubjs)}(hX**Parameters** ``struct pardevice *dev`` a device on the parallel port **Description** This function relinquishes the port if it would be helpful to other drivers to do so. Afterwards it tries to reclaim the port using parport_claim(), and the return value is the same as for parport_claim(). If it fails, the port is left unclaimed and it is the driver's responsibility to reclaim the port. The parport_yield() and parport_yield_blocking() functions are for marking points in the driver at which other drivers may claim the port and use their devices. Yielding the port is similar to releasing it and reclaiming it, but is more efficient because no action is taken if there are no other devices needing the port. In fact, nothing is done even if there are other devices waiting but the current device is still within its "timeslice". The default timeslice is half a second, but it can be adjusted via the /proc interface.h](j<)}(h**Parameters**h]j})}(hjh]h Parameters}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjubah}(h]h ]h"]h$]h&]uh1j;h_/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:4: ./include/linux/parport.hhMhj{ubj)}(hhh]j)}(h8``struct pardevice *dev`` a device on the parallel port h](j)}(h``struct pardevice *dev``h]jB)}(hjh]hstruct pardevice *dev}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhjubah}(h]h ]h"]h$]h&]uh1jh_/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:4: ./include/linux/parport.hhMhjubj)}(hhh]j<)}(ha device on the parallel porth]ha device on the parallel port}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hjhMhjubah}(h]h ]h"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]uh1jhjhMhjubah}(h]h ]h"]h$]h&]uh1jhj{ubj<)}(h**Description**h]j})}(hjh]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjubah}(h]h ]h"]h$]h&]uh1j;h_/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:4: ./include/linux/parport.hhMhj{ubj<)}(hX2This function relinquishes the port if it would be helpful to other drivers to do so. Afterwards it tries to reclaim the port using parport_claim(), and the return value is the same as for parport_claim(). If it fails, the port is left unclaimed and it is the driver's responsibility to reclaim the port.h]hX4This function relinquishes the port if it would be helpful to other drivers to do so. Afterwards it tries to reclaim the port using parport_claim(), and the return value is the same as for parport_claim(). If it fails, the port is left unclaimed and it is the driver’s responsibility to reclaim the port.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j;h_/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:4: ./include/linux/parport.hhMhj{ubj<)}(hXThe parport_yield() and parport_yield_blocking() functions are for marking points in the driver at which other drivers may claim the port and use their devices. Yielding the port is similar to releasing it and reclaiming it, but is more efficient because no action is taken if there are no other devices needing the port. In fact, nothing is done even if there are other devices waiting but the current device is still within its "timeslice". The default timeslice is half a second, but it can be adjusted via the /proc interface.h]hXThe parport_yield() and parport_yield_blocking() functions are for marking points in the driver at which other drivers may claim the port and use their devices. Yielding the port is similar to releasing it and reclaiming it, but is more efficient because no action is taken if there are no other devices needing the port. In fact, nothing is done even if there are other devices waiting but the current device is still within its “timeslice”. The default timeslice is half a second, but it can be adjusted via the /proc interface.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j;h_/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:4: ./include/linux/parport.hhMhj{ubeh}(h]h ] kernelindentah"]h$]h&]uh1jrhhhhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](h،#parport_yield_blocking (C function)c.parport_yield_blockinghNtauh1hhhhhhNhNubh)}(hhh](h)}(h2int parport_yield_blocking (struct pardevice *dev)h]h)}(h1int parport_yield_blocking(struct pardevice *dev)h](j)}(hinth]hint}(hj/hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj+hhh_/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:4: ./include/linux/parport.hhMubj)}(h h]h }(hj>hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj+hhhj=hMubh)}(hparport_yield_blockingh]h)}(hparport_yield_blockingh]hparport_yield_blocking}(hjPhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjLubah}(h]h ](jjeh"]h$]h&]j j uh1hhj+hhhj=hMubj)}(h(struct pardevice *dev)h]j)}(hstruct pardevice *devh](j)}(hjh]hstruct}(hjlhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjhubj)}(h h]h }(hjyhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjhubh)}(hhh]h)}(h pardeviceh]h pardevice}(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetjmodnameN classnameNjj )}j]j)}jjRsbc.parport_yield_blockingasbuh1hhjhubj)}(h h]h }(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjhubj%)}(hj(h]h*}(hjhhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hjhubh)}(hdevh]hdev}(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjhubeh}(h]h ]h"]h$]h&]noemphj j uh1jhjdubah}(h]h ]h"]h$]h&]j j uh1jhj+hhhj=hMubeh}(h]h ]h"]h$]h&]j j juh1hjjhj'hhhj=hMubah}(h]j"ah ](jjeh"]h$]h&]jj )j!huh1hhj=hMhj$hhubj#)}(hhh]j<)}(h&relinquish a parallel port temporarilyh]h&relinquish a parallel port temporarily}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j;h_/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:4: ./include/linux/parport.hhMhjhhubah}(h]h ]h"]h$]h&]uh1j"hj$hhhj=hMubeh}(h]h ](j0functioneh"]h$]h&]j5j0j6jj7jj8j9j:uh1hhhhhhNhNubjs)}(hX<**Parameters** ``struct pardevice *dev`` a device on the parallel port **Description** This function relinquishes the port if it would be helpful to other drivers to do so. Afterwards it tries to reclaim the port using parport_claim_or_block(), and the return value is the same as for parport_claim_or_block().h](j<)}(h**Parameters**h]j})}(hjh]h Parameters}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjubah}(h]h ]h"]h$]h&]uh1j;h_/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:4: ./include/linux/parport.hhMhj ubj)}(hhh]j)}(h8``struct pardevice *dev`` a device on the parallel port h](j)}(h``struct pardevice *dev``h]jB)}(hj0h]hstruct pardevice *dev}(hj2hhhNhNubah}(h]h ]h"]h$]h&]uh1jAhj.ubah}(h]h ]h"]h$]h&]uh1jh_/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:4: ./include/linux/parport.hhMhj*ubj)}(hhh]j<)}(ha device on the parallel porth]ha device on the parallel port}(hjIhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hjEhMhjFubah}(h]h ]h"]h$]h&]uh1jhj*ubeh}(h]h ]h"]h$]h&]uh1jhjEhMhj'ubah}(h]h ]h"]h$]h&]uh1jhj ubj<)}(h**Description**h]j})}(hjkh]h Description}(hjmhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjiubah}(h]h ]h"]h$]h&]uh1j;h_/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:4: ./include/linux/parport.hhMhj ubj<)}(hThis function relinquishes the port if it would be helpful to other drivers to do so. Afterwards it tries to reclaim the port using parport_claim_or_block(), and the return value is the same as for parport_claim_or_block().h]hThis function relinquishes the port if it would be helpful to other drivers to do so. Afterwards it tries to reclaim the port using parport_claim_or_block(), and the return value is the same as for parport_claim_or_block().}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j;h_/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:4: ./include/linux/parport.hhMhj ubeh}(h]h ] kernelindentah"]h$]h&]uh1jrhhhhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](h،parport_wait_event (C function)c.parport_wait_eventhNtauh1hhhhhhNhNubh)}(hhh](h)}(hBint parport_wait_event (struct parport *port, signed long timeout)h]h)}(hAint parport_wait_event(struct parport *port, signed long timeout)h](j)}(hinth]hint}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjhhhb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chK1ubj)}(h h]h }(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjhhhjhK1ubh)}(hparport_wait_eventh]h)}(hparport_wait_eventh]hparport_wait_event}(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubah}(h]h ](jjeh"]h$]h&]j j uh1hhjhhhjhK1ubj)}(h+(struct parport *port, signed long timeout)h](j)}(hstruct parport *porth](j)}(hjh]hstruct}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubh)}(hhh]h)}(hparporth]hparport}(hj hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetj modnameN classnameNjj )}j]j)}jjsbc.parport_wait_eventasbuh1hhjubj)}(h h]h }(hj+hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj%)}(hj(h]h*}(hj9hhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hjubh)}(hporth]hport}(hjFhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubeh}(h]h ]h"]h$]h&]noemphj j uh1jhjubj)}(hsigned long timeouth](j)}(hsignedh]hsigned}(hj_hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj[ubj)}(h h]h }(hjmhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj[ubj)}(hlongh]hlong}(hj{hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj[ubj)}(h h]h }(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj[ubh)}(htimeouth]htimeout}(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj[ubeh}(h]h ]h"]h$]h&]noemphj j uh1jhjubeh}(h]h ]h"]h$]h&]j j uh1jhjhhhjhK1ubeh}(h]h ]h"]h$]h&]j j juh1hjjhjhhhjhK1ubah}(h]jah ](jjeh"]h$]h&]jj )j!huh1hhjhK1hjhhubj#)}(hhh]j<)}(h$wait for an event on a parallel porth]h$wait for an event on a parallel port}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chK1hjhhubah}(h]h ]h"]h$]h&]uh1j"hjhhhjhK1ubeh}(h]h ](j0functioneh"]h$]h&]j5j0j6jj7jj8j9j:uh1hhhhhhNhNubjs)}(hXb**Parameters** ``struct parport *port`` port to wait on ``signed long timeout`` time to wait (in jiffies) **Description** This function waits for up to **timeout** jiffies for an interrupt to occur on a parallel port. If the port timeout is set to zero, it returns immediately. If an interrupt occurs before the timeout period elapses, this function returns zero immediately. If it times out, it returns one. An error code less than zero indicates an error (most likely a pending signal), and the calling code should finish what it's doing as soon as it can.h](j<)}(h**Parameters**h]j})}(hjh]h Parameters}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjubah}(h]h ]h"]h$]h&]uh1j;hb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chK5hjubj)}(hhh](j)}(h)``struct parport *port`` port to wait on h](j)}(h``struct parport *port``h]jB)}(hjh]hstruct parport *port}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhjubah}(h]h ]h"]h$]h&]uh1jhb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chK2hjubj)}(hhh]j<)}(hport to wait onh]hport to wait on}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hjhK2hjubah}(h]h ]h"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]uh1jhjhK2hjubj)}(h2``signed long timeout`` time to wait (in jiffies) h](j)}(h``signed long timeout``h]jB)}(hj;h]hsigned long timeout}(hj=hhhNhNubah}(h]h ]h"]h$]h&]uh1jAhj9ubah}(h]h ]h"]h$]h&]uh1jhb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chK3hj5ubj)}(hhh]j<)}(htime to wait (in jiffies)h]htime to wait (in jiffies)}(hjThhhNhNubah}(h]h ]h"]h$]h&]uh1j;hjPhK3hjQubah}(h]h ]h"]h$]h&]uh1jhj5ubeh}(h]h ]h"]h$]h&]uh1jhjPhK3hjubeh}(h]h ]h"]h$]h&]uh1jhjubj<)}(h**Description**h]j})}(hjvh]h Description}(hjxhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjtubah}(h]h ]h"]h$]h&]uh1j;hb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chK5hjubjX)}(hXThis function waits for up to **timeout** jiffies for an interrupt to occur on a parallel port. If the port timeout is set to zero, it returns immediately. If an interrupt occurs before the timeout period elapses, this function returns zero immediately. If it times out, it returns one. An error code less than zero indicates an error (most likely a pending signal), and the calling code should finish what it's doing as soon as it can.h](j<)}(hThis function waits for up to **timeout** jiffies for an interrupt to occur on a parallel port. If the port timeout is set to zero, it returns immediately.h](hThis function waits for up to }(hjhhhNhNubj})}(h **timeout**h]htimeout}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjubhs jiffies for an interrupt to occur on a parallel port. If the port timeout is set to zero, it returns immediately.}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1j;hb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chK4hjubj<)}(hXIf an interrupt occurs before the timeout period elapses, this function returns zero immediately. If it times out, it returns one. An error code less than zero indicates an error (most likely a pending signal), and the calling code should finish what it's doing as soon as it can.h]hXIf an interrupt occurs before the timeout period elapses, this function returns zero immediately. If it times out, it returns one. An error code less than zero indicates an error (most likely a pending signal), and the calling code should finish what it’s doing as soon as it can.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chK8hjubeh}(h]h ]h"]h$]h&]uh1jWhjhK4hjubeh}(h]h ] kernelindentah"]h$]h&]uh1jrhhhhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](h،$parport_wait_peripheral (C function)c.parport_wait_peripheralhNtauh1hhhhhhNhNubh)}(hhh](h)}(h\int parport_wait_peripheral (struct parport *port, unsigned char mask, unsigned char result)h]h)}(h[int parport_wait_peripheral(struct parport *port, unsigned char mask, unsigned char result)h](j)}(hinth]hint}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjhhhb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chKubj)}(h h]h }(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjhhhjhKubh)}(hparport_wait_peripheralh]h)}(hparport_wait_peripheralh]hparport_wait_peripheral}(hj hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj ubah}(h]h ](jjeh"]h$]h&]j j uh1hhjhhhjhKubj)}(h@(struct parport *port, unsigned char mask, unsigned char result)h](j)}(hstruct parport *porth](j)}(hjh]hstruct}(hj# hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj ubj)}(h h]h }(hj0 hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj ubh)}(hhh]h)}(hparporth]hparport}(hjA hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj> ubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetjC modnameN classnameNjj )}j]j)}jj sbc.parport_wait_peripheralasbuh1hhj ubj)}(h h]h }(hja hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj ubj%)}(hj(h]h*}(hjo hhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hj ubh)}(hporth]hport}(hj| hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj ubeh}(h]h ]h"]h$]h&]noemphj j uh1jhj ubj)}(hunsigned char maskh](j)}(hunsignedh]hunsigned}(hj hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj ubj)}(h h]h }(hj hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj ubj)}(hcharh]hchar}(hj hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj ubj)}(h h]h }(hj hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj ubh)}(hmaskh]hmask}(hj hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj ubeh}(h]h ]h"]h$]h&]noemphj j uh1jhj ubj)}(hunsigned char resulth](j)}(hunsignedh]hunsigned}(hj hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj ubj)}(h h]h }(hj hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj ubj)}(hcharh]hchar}(hj hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj ubj)}(h h]h }(hj hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj ubh)}(hresulth]hresult}(hj hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj ubeh}(h]h ]h"]h$]h&]noemphj j uh1jhj ubeh}(h]h ]h"]h$]h&]j j uh1jhjhhhjhKubeh}(h]h ]h"]h$]h&]j j juh1hjjhjhhhjhKubah}(h]jah ](jjeh"]h$]h&]jj )j!huh1hhjhKhjhhubj#)}(hhh]j<)}(h'wait for status lines to change in 35msh]h'wait for status lines to change in 35ms}(hjH hhhNhNubah}(h]h ]h"]h$]h&]uh1j;hb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chKhjE hhubah}(h]h ]h"]h$]h&]uh1j"hjhhhjhKubeh}(h]h ](j0functioneh"]h$]h&]j5j0j6j` j7j` j8j9j:uh1hhhhhhNhNubjs)}(hX0**Parameters** ``struct parport *port`` port to watch ``unsigned char mask`` status lines to watch ``unsigned char result`` desired values of chosen status lines **Description** This function waits until the masked status lines have the desired values, or until 35ms have elapsed (see IEEE 1284-1994 page 24 to 25 for why this value in particular is hardcoded). The **mask** and **result** parameters are bitmasks, with the bits defined by the constants in parport.h: ``PARPORT_STATUS_BUSY``, and so on. The port is polled quickly to start off with, in anticipation of a fast response from the peripheral. This fast polling time is configurable (using /proc), and defaults to 500usec. If the timeout for this port (see parport_set_timeout()) is zero, the fast polling time is 35ms, and this function does not call schedule(). If the timeout for this port is non-zero, after the fast polling fails it uses parport_wait_event() to wait for up to 10ms, waking up if an interrupt occurs.h](j<)}(h**Parameters**h]j})}(hjj h]h Parameters}(hjl hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjh ubah}(h]h ]h"]h$]h&]uh1j;hb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chKhjd ubj)}(hhh](j)}(h'``struct parport *port`` port to watch h](j)}(h``struct parport *port``h]jB)}(hj h]hstruct parport *port}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jAhj ubah}(h]h ]h"]h$]h&]uh1jhb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chKhj ubj)}(hhh]j<)}(h port to watchh]h port to watch}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1j;hj hKhj ubah}(h]h ]h"]h$]h&]uh1jhj ubeh}(h]h ]h"]h$]h&]uh1jhj hKhj ubj)}(h-``unsigned char mask`` status lines to watch h](j)}(h``unsigned char mask``h]jB)}(hj h]hunsigned char mask}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jAhj ubah}(h]h ]h"]h$]h&]uh1jhb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chKhj ubj)}(hhh]j<)}(hstatus lines to watchh]hstatus lines to watch}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1j;hj hKhj ubah}(h]h ]h"]h$]h&]uh1jhj ubeh}(h]h ]h"]h$]h&]uh1jhj hKhj ubj)}(h?``unsigned char result`` desired values of chosen status lines h](j)}(h``unsigned char result``h]jB)}(hj h]hunsigned char result}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jAhj ubah}(h]h ]h"]h$]h&]uh1jhb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chKhj ubj)}(hhh]j<)}(h%desired values of chosen status linesh]h%desired values of chosen status lines}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1j;hj hKhj ubah}(h]h ]h"]h$]h&]uh1jhj ubeh}(h]h ]h"]h$]h&]uh1jhj hKhj ubeh}(h]h ]h"]h$]h&]uh1jhjd ubj<)}(h**Description**h]j})}(hj6 h]h Description}(hj8 hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj4 ubah}(h]h ]h"]h$]h&]uh1j;hb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chKhjd ubjX)}(hX(This function waits until the masked status lines have the desired values, or until 35ms have elapsed (see IEEE 1284-1994 page 24 to 25 for why this value in particular is hardcoded). The **mask** and **result** parameters are bitmasks, with the bits defined by the constants in parport.h: ``PARPORT_STATUS_BUSY``, and so on. The port is polled quickly to start off with, in anticipation of a fast response from the peripheral. This fast polling time is configurable (using /proc), and defaults to 500usec. If the timeout for this port (see parport_set_timeout()) is zero, the fast polling time is 35ms, and this function does not call schedule(). If the timeout for this port is non-zero, after the fast polling fails it uses parport_wait_event() to wait for up to 10ms, waking up if an interrupt occurs.h](j<)}(hXEThis function waits until the masked status lines have the desired values, or until 35ms have elapsed (see IEEE 1284-1994 page 24 to 25 for why this value in particular is hardcoded). The **mask** and **result** parameters are bitmasks, with the bits defined by the constants in parport.h: ``PARPORT_STATUS_BUSY``, and so on.h](hThis function waits until the masked status lines have the desired values, or until 35ms have elapsed (see IEEE 1284-1994 page 24 to 25 for why this value in particular is hardcoded). The }(hjP hhhNhNubj})}(h**mask**h]hmask}(hjX hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjP ubh and }(hjP hhhNhNubj})}(h **result**h]hresult}(hjj hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjP ubhO parameters are bitmasks, with the bits defined by the constants in parport.h: }(hjP hhhNhNubjB)}(h``PARPORT_STATUS_BUSY``h]hPARPORT_STATUS_BUSY}(hj| hhhNhNubah}(h]h ]h"]h$]h&]uh1jAhjP ubh , and so on.}(hjP hhhNhNubeh}(h]h ]h"]h$]h&]uh1j;hb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chKhjL ubj<)}(hXBThe port is polled quickly to start off with, in anticipation of a fast response from the peripheral. This fast polling time is configurable (using /proc), and defaults to 500usec. If the timeout for this port (see parport_set_timeout()) is zero, the fast polling time is 35ms, and this function does not call schedule().h]hXBThe port is polled quickly to start off with, in anticipation of a fast response from the peripheral. This fast polling time is configurable (using /proc), and defaults to 500usec. If the timeout for this port (see parport_set_timeout()) is zero, the fast polling time is 35ms, and this function does not call schedule().}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1j;hb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chKhjL ubj<)}(hIf the timeout for this port is non-zero, after the fast polling fails it uses parport_wait_event() to wait for up to 10ms, waking up if an interrupt occurs.h]hIf the timeout for this port is non-zero, after the fast polling fails it uses parport_wait_event() to wait for up to 10ms, waking up if an interrupt occurs.}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1j;hb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chKhjL ubeh}(h]h ]h"]h$]h&]uh1jWhj hKhjd ubeh}(h]h ] kernelindentah"]h$]h&]uh1jrhhhhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](h،parport_negotiate (C function)c.parport_negotiatehNtauh1hhhhhhNhNubh)}(hhh](h)}(h6int parport_negotiate (struct parport *port, int mode)h]h)}(h5int parport_negotiate(struct parport *port, int mode)h](j)}(hinth]hint}(hj hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj hhhb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chM/ubj)}(h h]h }(hj hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj hhhj hM/ubh)}(hparport_negotiateh]h)}(hparport_negotiateh]hparport_negotiate}(hj hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj ubah}(h]h ](jjeh"]h$]h&]j j uh1hhj hhhj hM/ubj)}(h (struct parport *port, int mode)h](j)}(hstruct parport *porth](j)}(hjh]hstruct}(hj hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj ubj)}(h h]h }(hj# hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj ubh)}(hhh]h)}(hparporth]hparport}(hj4 hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj1 ubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetj6 modnameN classnameNjj )}j]j)}jj sbc.parport_negotiateasbuh1hhj ubj)}(h h]h }(hjT hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj ubj%)}(hj(h]h*}(hjb hhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hj ubh)}(hporth]hport}(hjo hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj ubeh}(h]h ]h"]h$]h&]noemphj j uh1jhj ubj)}(hint modeh](j)}(hinth]hint}(hj hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj ubj)}(h h]h }(hj hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj ubh)}(hmodeh]hmode}(hj hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj ubeh}(h]h ]h"]h$]h&]noemphj j uh1jhj ubeh}(h]h ]h"]h$]h&]j j uh1jhj hhhj hM/ubeh}(h]h ]h"]h$]h&]j j juh1hjjhj hhhj hM/ubah}(h]j ah ](jjeh"]h$]h&]jj )j!huh1hhj hM/hj hhubj#)}(hhh]j<)}(hnegotiate an IEEE 1284 modeh]hnegotiate an IEEE 1284 mode}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1j;hb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chM/hj hhubah}(h]h ]h"]h$]h&]uh1j"hj hhhj hM/ubeh}(h]h ](j0functioneh"]h$]h&]j5j0j6j j7j j8j9j:uh1hhhhhhNhNubjs)}(hX**Parameters** ``struct parport *port`` port to use ``int mode`` mode to negotiate to **Description** Use this to negotiate to a particular IEEE 1284 transfer mode. The **mode** parameter should be one of the constants in parport.h starting ``IEEE1284_MODE_xxx``. The return value is 0 if the peripheral has accepted the negotiation to the mode specified, -1 if the peripheral is not IEEE 1284 compliant (or not present), or 1 if the peripheral has rejected the negotiation.h](j<)}(h**Parameters**h]j})}(hj h]h Parameters}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj ubah}(h]h ]h"]h$]h&]uh1j;hb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chM3hj ubj)}(hhh](j)}(h%``struct parport *port`` port to use h](j)}(h``struct parport *port``h]jB)}(hj h]hstruct parport *port}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jAhj ubah}(h]h ]h"]h$]h&]uh1jhb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chM0hj ubj)}(hhh]j<)}(h port to useh]h port to use}(hj( hhhNhNubah}(h]h ]h"]h$]h&]uh1j;hj$ hM0hj% ubah}(h]h ]h"]h$]h&]uh1jhj ubeh}(h]h ]h"]h$]h&]uh1jhj$ hM0hj ubj)}(h"``int mode`` mode to negotiate to h](j)}(h ``int mode``h]jB)}(hjH h]hint mode}(hjJ hhhNhNubah}(h]h ]h"]h$]h&]uh1jAhjF ubah}(h]h ]h"]h$]h&]uh1jhb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chM1hjB ubj)}(hhh]j<)}(hmode to negotiate toh]hmode to negotiate to}(hja hhhNhNubah}(h]h ]h"]h$]h&]uh1j;hj] hM1hj^ ubah}(h]h ]h"]h$]h&]uh1jhjB ubeh}(h]h ]h"]h$]h&]uh1jhj] hM1hj ubeh}(h]h ]h"]h$]h&]uh1jhj ubj<)}(h**Description**h]j})}(hj h]h Description}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj ubah}(h]h ]h"]h$]h&]uh1j;hb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chM3hj ubjX)}(hXuUse this to negotiate to a particular IEEE 1284 transfer mode. The **mode** parameter should be one of the constants in parport.h starting ``IEEE1284_MODE_xxx``. The return value is 0 if the peripheral has accepted the negotiation to the mode specified, -1 if the peripheral is not IEEE 1284 compliant (or not present), or 1 if the peripheral has rejected the negotiation.h](j<)}(hUse this to negotiate to a particular IEEE 1284 transfer mode. The **mode** parameter should be one of the constants in parport.h starting ``IEEE1284_MODE_xxx``.h](hCUse this to negotiate to a particular IEEE 1284 transfer mode. The }(hj hhhNhNubj})}(h**mode**h]hmode}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj ubh@ parameter should be one of the constants in parport.h starting }(hj hhhNhNubjB)}(h``IEEE1284_MODE_xxx``h]hIEEE1284_MODE_xxx}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jAhj ubh.}(hj hhhNhNubeh}(h]h ]h"]h$]h&]uh1j;hb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chM2hj ubj<)}(hThe return value is 0 if the peripheral has accepted the negotiation to the mode specified, -1 if the peripheral is not IEEE 1284 compliant (or not present), or 1 if the peripheral has rejected the negotiation.h]hThe return value is 0 if the peripheral has accepted the negotiation to the mode specified, -1 if the peripheral is not IEEE 1284 compliant (or not present), or 1 if the peripheral has rejected the negotiation.}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1j;hb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chM6hj ubeh}(h]h ]h"]h$]h&]uh1jWhj hM2hj ubeh}(h]h ] kernelindentah"]h$]h&]uh1jrhhhhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](h،parport_write (C function)c.parport_writehNtauh1hhhhhhNhNubh)}(hhh](h)}(hLssize_t parport_write (struct parport *port, const void *buffer, size_t len)h]h)}(hKssize_t parport_write(struct parport *port, const void *buffer, size_t len)h](h)}(hhh]h)}(hssize_th]hssize_t}(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetj modnameN classnameNjj )}j]j)}j parport_writesbc.parport_writeasbuh1hhjhhhb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chM6ubj)}(h h]h }(hj*hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjhhhj)hM6ubh)}(h parport_writeh]h)}(hj&h]h parport_write}(hj<hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj8ubah}(h]h ](jjeh"]h$]h&]j j uh1hhjhhhj)hM6ubj)}(h6(struct parport *port, const void *buffer, size_t len)h](j)}(hstruct parport *porth](j)}(hjh]hstruct}(hjWhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjSubj)}(h h]h }(hjdhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjSubh)}(hhh]h)}(hparporth]hparport}(hjuhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjrubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetjwmodnameN classnameNjj )}j]j$c.parport_writeasbuh1hhjSubj)}(h h]h }(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjSubj%)}(hj(h]h*}(hjhhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hjSubh)}(hporth]hport}(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjSubeh}(h]h ]h"]h$]h&]noemphj j uh1jhjOubj)}(hconst void *bufferh](j)}(hconsth]hconst}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(hvoidh]hvoid}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj%)}(hj(h]h*}(hjhhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hjubh)}(hbufferh]hbuffer}(hj hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubeh}(h]h ]h"]h$]h&]noemphj j uh1jhjOubj)}(h size_t lenh](h)}(hhh]h)}(hsize_th]hsize_t}(hj(hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj%ubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetj*modnameN classnameNjj )}j]j$c.parport_writeasbuh1hhj!ubj)}(h h]h }(hjFhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj!ubh)}(hlenh]hlen}(hjThhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj!ubeh}(h]h ]h"]h$]h&]noemphj j uh1jhjOubeh}(h]h ]h"]h$]h&]j j uh1jhjhhhj)hM6ubeh}(h]h ]h"]h$]h&]j j juh1hjjhj hhhj)hM6ubah}(h]j ah ](jjeh"]h$]h&]jj )j!huh1hhj)hM6hj hhubj#)}(hhh]j<)}(h(write a block of data to a parallel porth]h(write a block of data to a parallel port}(hj~hhhNhNubah}(h]h ]h"]h$]h&]uh1j;hb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chM6hj{hhubah}(h]h ]h"]h$]h&]uh1j"hj hhhj)hM6ubeh}(h]h ](j0functioneh"]h$]h&]j5j0j6jj7jj8j9j:uh1hhhhhhNhNubjs)}(hX**Parameters** ``struct parport *port`` port to write to ``const void *buffer`` data buffer (in kernel space) ``size_t len`` number of bytes of data to transfer **Description** This will write up to **len** bytes of **buffer** to the port specified, using the IEEE 1284 transfer mode most recently negotiated to (using parport_negotiate()), as long as that mode supports forward transfers (host to peripheral). It is the caller's responsibility to ensure that the first **len** bytes of **buffer** are valid. This function returns the number of bytes transferred (if zero or positive), or else an error code.h](j<)}(h**Parameters**h]j})}(hjh]h Parameters}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjubah}(h]h ]h"]h$]h&]uh1j;hb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chM:hjubj)}(hhh](j)}(h*``struct parport *port`` port to write to h](j)}(h``struct parport *port``h]jB)}(hjh]hstruct parport *port}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhjubah}(h]h ]h"]h$]h&]uh1jhb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chM7hjubj)}(hhh]j<)}(hport to write toh]hport to write to}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hjhM7hjubah}(h]h ]h"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]uh1jhjhM7hjubj)}(h5``const void *buffer`` data buffer (in kernel space) h](j)}(h``const void *buffer``h]jB)}(hjh]hconst void *buffer}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhjubah}(h]h ]h"]h$]h&]uh1jhb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chM8hjubj)}(hhh]j<)}(hdata buffer (in kernel space)h]hdata buffer (in kernel space)}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hj hM8hjubah}(h]h ]h"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]uh1jhj hM8hjubj)}(h3``size_t len`` number of bytes of data to transfer h](j)}(h``size_t len``h]jB)}(hj1h]h size_t len}(hj3hhhNhNubah}(h]h ]h"]h$]h&]uh1jAhj/ubah}(h]h ]h"]h$]h&]uh1jhb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chM9hj+ubj)}(hhh]j<)}(h#number of bytes of data to transferh]h#number of bytes of data to transfer}(hjJhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hjFhM9hjGubah}(h]h ]h"]h$]h&]uh1jhj+ubeh}(h]h ]h"]h$]h&]uh1jhjFhM9hjubeh}(h]h ]h"]h$]h&]uh1jhjubj<)}(h**Description**h]j})}(hjlh]h Description}(hjnhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjjubah}(h]h ]h"]h$]h&]uh1j;hb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chM;hjubjX)}(hXThis will write up to **len** bytes of **buffer** to the port specified, using the IEEE 1284 transfer mode most recently negotiated to (using parport_negotiate()), as long as that mode supports forward transfers (host to peripheral). It is the caller's responsibility to ensure that the first **len** bytes of **buffer** are valid. This function returns the number of bytes transferred (if zero or positive), or else an error code.h](j<)}(hThis will write up to **len** bytes of **buffer** to the port specified, using the IEEE 1284 transfer mode most recently negotiated to (using parport_negotiate()), as long as that mode supports forward transfers (host to peripheral).h](hThis will write up to }(hjhhhNhNubj})}(h**len**h]hlen}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjubh bytes of }(hjhhhNhNubj})}(h **buffer**h]hbuffer}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjubh to the port specified, using the IEEE 1284 transfer mode most recently negotiated to (using parport_negotiate()), as long as that mode supports forward transfers (host to peripheral).}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1j;hb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chM:hjubj<)}(haIt is the caller's responsibility to ensure that the first **len** bytes of **buffer** are valid.h](h=It is the caller’s responsibility to ensure that the first }(hjhhhNhNubj})}(h**len**h]hlen}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjubh bytes of }(hjhhhNhNubj})}(h **buffer**h]hbuffer}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjubh are valid.}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1j;hb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chM?hjubj<)}(hcThis function returns the number of bytes transferred (if zero or positive), or else an error code.h]hcThis function returns the number of bytes transferred (if zero or positive), or else an error code.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chMBhjubeh}(h]h ]h"]h$]h&]uh1jWhjhM:hjubeh}(h]h ] kernelindentah"]h$]h&]uh1jrhhhhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](h،parport_read (C function)c.parport_readhNtauh1hhhhhhNhNubh)}(hhh](h)}(hEssize_t parport_read (struct parport *port, void *buffer, size_t len)h]h)}(hDssize_t parport_read(struct parport *port, void *buffer, size_t len)h](h)}(hhh]h)}(hssize_th]hssize_t}(hj$hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj!ubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetj&modnameN classnameNjj )}j]j)}j parport_readsbc.parport_readasbuh1hhjhhhb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chMubj)}(h h]h }(hjFhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjhhhjEhMubh)}(h parport_readh]h)}(hjBh]h parport_read}(hjXhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjTubah}(h]h ](jjeh"]h$]h&]j j uh1hhjhhhjEhMubj)}(h0(struct parport *port, void *buffer, size_t len)h](j)}(hstruct parport *porth](j)}(hjh]hstruct}(hjshhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjoubj)}(h h]h }(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjoubh)}(hhh]h)}(hparporth]hparport}(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetjmodnameN classnameNjj )}j]j@c.parport_readasbuh1hhjoubj)}(h h]h }(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjoubj%)}(hj(h]h*}(hjhhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hjoubh)}(hporth]hport}(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjoubeh}(h]h ]h"]h$]h&]noemphj j uh1jhjkubj)}(h void *bufferh](j)}(hvoidh]hvoid}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj%)}(hj(h]h*}(hjhhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hjubh)}(hbufferh]hbuffer}(hj hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubeh}(h]h ]h"]h$]h&]noemphj j uh1jhjkubj)}(h size_t lenh](h)}(hhh]h)}(hsize_th]hsize_t}(hj(hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj%ubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetj*modnameN classnameNjj )}j]j@c.parport_readasbuh1hhj!ubj)}(h h]h }(hjFhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj!ubh)}(hlenh]hlen}(hjThhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj!ubeh}(h]h ]h"]h$]h&]noemphj j uh1jhjkubeh}(h]h ]h"]h$]h&]j j uh1jhjhhhjEhMubeh}(h]h ]h"]h$]h&]j j juh1hjjhjhhhjEhMubah}(h]jah ](jjeh"]h$]h&]jj )j!huh1hhjEhMhjhhubj#)}(hhh]j<)}(h)read a block of data from a parallel porth]h)read a block of data from a parallel port}(hj~hhhNhNubah}(h]h ]h"]h$]h&]uh1j;hb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chMhj{hhubah}(h]h ]h"]h$]h&]uh1j"hjhhhjEhMubeh}(h]h ](j0functioneh"]h$]h&]j5j0j6jj7jj8j9j:uh1hhhhhhNhNubjs)}(hX**Parameters** ``struct parport *port`` port to read from ``void *buffer`` data buffer (in kernel space) ``size_t len`` number of bytes of data to transfer **Description** This will read up to **len** bytes of **buffer** to the port specified, using the IEEE 1284 transfer mode most recently negotiated to (using parport_negotiate()), as long as that mode supports reverse transfers (peripheral to host). It is the caller's responsibility to ensure that the first **len** bytes of **buffer** are available to write to. This function returns the number of bytes transferred (if zero or positive), or else an error code.h](j<)}(h**Parameters**h]j})}(hjh]h Parameters}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjubah}(h]h ]h"]h$]h&]uh1j;hb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chMhjubj)}(hhh](j)}(h+``struct parport *port`` port to read from h](j)}(h``struct parport *port``h]jB)}(hjh]hstruct parport *port}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhjubah}(h]h ]h"]h$]h&]uh1jhb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chMhjubj)}(hhh]j<)}(hport to read fromh]hport to read from}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hjhMhjubah}(h]h ]h"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]uh1jhjhMhjubj)}(h/``void *buffer`` data buffer (in kernel space) h](j)}(h``void *buffer``h]jB)}(hjh]h void *buffer}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhjubah}(h]h ]h"]h$]h&]uh1jhb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chMhjubj)}(hhh]j<)}(hdata buffer (in kernel space)h]hdata buffer (in kernel space)}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hj hMhjubah}(h]h ]h"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]uh1jhj hMhjubj)}(h3``size_t len`` number of bytes of data to transfer h](j)}(h``size_t len``h]jB)}(hj1h]h size_t len}(hj3hhhNhNubah}(h]h ]h"]h$]h&]uh1jAhj/ubah}(h]h ]h"]h$]h&]uh1jhb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chMhj+ubj)}(hhh]j<)}(h#number of bytes of data to transferh]h#number of bytes of data to transfer}(hjJhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hjFhMhjGubah}(h]h ]h"]h$]h&]uh1jhj+ubeh}(h]h ]h"]h$]h&]uh1jhjFhMhjubeh}(h]h ]h"]h$]h&]uh1jhjubj<)}(h**Description**h]j})}(hjlh]h Description}(hjnhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjjubah}(h]h ]h"]h$]h&]uh1j;hb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chMhjubjX)}(hXThis will read up to **len** bytes of **buffer** to the port specified, using the IEEE 1284 transfer mode most recently negotiated to (using parport_negotiate()), as long as that mode supports reverse transfers (peripheral to host). It is the caller's responsibility to ensure that the first **len** bytes of **buffer** are available to write to. This function returns the number of bytes transferred (if zero or positive), or else an error code.h](j<)}(hThis will read up to **len** bytes of **buffer** to the port specified, using the IEEE 1284 transfer mode most recently negotiated to (using parport_negotiate()), as long as that mode supports reverse transfers (peripheral to host).h](hThis will read up to }(hjhhhNhNubj})}(h**len**h]hlen}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjubh bytes of }(hjhhhNhNubj})}(h **buffer**h]hbuffer}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjubh to the port specified, using the IEEE 1284 transfer mode most recently negotiated to (using parport_negotiate()), as long as that mode supports reverse transfers (peripheral to host).}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1j;hb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chMhjubj<)}(hqIt is the caller's responsibility to ensure that the first **len** bytes of **buffer** are available to write to.h](h=It is the caller’s responsibility to ensure that the first }(hjhhhNhNubj})}(h**len**h]hlen}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjubh bytes of }(hjhhhNhNubj})}(h **buffer**h]hbuffer}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjubh are available to write to.}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1j;hb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chMhjubj<)}(hcThis function returns the number of bytes transferred (if zero or positive), or else an error code.h]hcThis function returns the number of bytes transferred (if zero or positive), or else an error code.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chMhjubeh}(h]h ]h"]h$]h&]uh1jWhjhMhjubeh}(h]h ] kernelindentah"]h$]h&]uh1jrhhhhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](h، parport_set_timeout (C function)c.parport_set_timeouthNtauh1hhhhhhNhNubh)}(hhh](h)}(hAlong parport_set_timeout (struct pardevice *dev, long inactivity)h]h)}(h@long parport_set_timeout(struct pardevice *dev, long inactivity)h](j)}(hlongh]hlong}(hj!hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjhhhb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chMubj)}(h h]h }(hj0hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjhhhj/hMubh)}(hparport_set_timeouth]h)}(hparport_set_timeouth]hparport_set_timeout}(hjBhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj>ubah}(h]h ](jjeh"]h$]h&]j j uh1hhjhhhj/hMubj)}(h((struct pardevice *dev, long inactivity)h](j)}(hstruct pardevice *devh](j)}(hjh]hstruct}(hj^hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjZubj)}(h h]h }(hjkhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjZubh)}(hhh]h)}(h pardeviceh]h pardevice}(hj|hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjyubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetj~modnameN classnameNjj )}j]j)}jjDsbc.parport_set_timeoutasbuh1hhjZubj)}(h h]h }(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjZubj%)}(hj(h]h*}(hjhhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hjZubh)}(hdevh]hdev}(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjZubeh}(h]h ]h"]h$]h&]noemphj j uh1jhjVubj)}(hlong inactivityh](j)}(hlongh]hlong}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubh)}(h inactivityh]h inactivity}(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubeh}(h]h ]h"]h$]h&]noemphj j uh1jhjVubeh}(h]h ]h"]h$]h&]j j uh1jhjhhhj/hMubeh}(h]h ]h"]h$]h&]j j juh1hjjhjhhhj/hMubah}(h]jah ](jjeh"]h$]h&]jj )j!huh1hhj/hMhjhhubj#)}(hhh]j<)}(h'set the inactivity timeout for a deviceh]h'set the inactivity timeout for a device}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chMhjhhubah}(h]h ]h"]h$]h&]uh1j"hjhhhj/hMubeh}(h]h ](j0functioneh"]h$]h&]j5j0j6j.j7j.j8j9j:uh1hhhhhhNhNubjs)}(hX**Parameters** ``struct pardevice *dev`` device on a port ``long inactivity`` inactivity timeout (in jiffies) **Description** This sets the inactivity timeout for a particular device on a port. This affects functions like parport_wait_peripheral(). The special value 0 means not to call schedule() while dealing with this device. The return value is the previous inactivity timeout. Any callers of parport_wait_event() for this device are woken up.h](j<)}(h**Parameters**h]j})}(hj8h]h Parameters}(hj:hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj6ubah}(h]h ]h"]h$]h&]uh1j;hb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chMhj2ubj)}(hhh](j)}(h+``struct pardevice *dev`` device on a port h](j)}(h``struct pardevice *dev``h]jB)}(hjWh]hstruct pardevice *dev}(hjYhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhjUubah}(h]h ]h"]h$]h&]uh1jhb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chMhjQubj)}(hhh]j<)}(hdevice on a porth]hdevice on a port}(hjphhhNhNubah}(h]h ]h"]h$]h&]uh1j;hjlhMhjmubah}(h]h ]h"]h$]h&]uh1jhjQubeh}(h]h ]h"]h$]h&]uh1jhjlhMhjNubj)}(h4``long inactivity`` inactivity timeout (in jiffies) h](j)}(h``long inactivity``h]jB)}(hjh]hlong inactivity}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhjubah}(h]h ]h"]h$]h&]uh1jhb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chMhjubj)}(hhh]j<)}(hinactivity timeout (in jiffies)h]hinactivity timeout (in jiffies)}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hjhMhjubah}(h]h ]h"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]uh1jhjhMhjNubeh}(h]h ]h"]h$]h&]uh1jhj2ubj<)}(h**Description**h]j})}(hjh]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjubah}(h]h ]h"]h$]h&]uh1j;hb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chMhj2ubjX)}(hXEThis sets the inactivity timeout for a particular device on a port. This affects functions like parport_wait_peripheral(). The special value 0 means not to call schedule() while dealing with this device. The return value is the previous inactivity timeout. Any callers of parport_wait_event() for this device are woken up.h](j<)}(hThis sets the inactivity timeout for a particular device on a port. This affects functions like parport_wait_peripheral(). The special value 0 means not to call schedule() while dealing with this device.h]hThis sets the inactivity timeout for a particular device on a port. This affects functions like parport_wait_peripheral(). The special value 0 means not to call schedule() while dealing with this device.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chMhjubj<)}(h4The return value is the previous inactivity timeout.h]h4The return value is the previous inactivity timeout.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chMhjubj<)}(hAAny callers of parport_wait_event() for this device are woken up.h]hAAny callers of parport_wait_event() for this device are woken up.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hb/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:7: ./drivers/parport/ieee1284.chMhjubeh}(h]h ]h"]h$]h&]uh1jWhjhMhj2ubeh}(h]h ] kernelindentah"]h$]h&]uh1jrhhhhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](h،&__parport_register_driver (C function)c.__parport_register_driverhNtauh1hhhhhhNhNubh)}(hhh](h)}(hfint __parport_register_driver (struct parport_driver *drv, struct module *owner, const char *mod_name)h]h)}(heint __parport_register_driver(struct parport_driver *drv, struct module *owner, const char *mod_name)h](j)}(hinth]hint}(hj8hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj4hhh`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chKubj)}(h h]h }(hjGhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj4hhhjFhKubh)}(h__parport_register_driverh]h)}(h__parport_register_driverh]h__parport_register_driver}(hjYhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjUubah}(h]h ](jjeh"]h$]h&]j j uh1hhj4hhhjFhKubj)}(hH(struct parport_driver *drv, struct module *owner, const char *mod_name)h](j)}(hstruct parport_driver *drvh](j)}(hjh]hstruct}(hjuhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjqubj)}(h h]h }(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjqubh)}(hhh]h)}(hparport_driverh]hparport_driver}(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetjmodnameN classnameNjj )}j]j)}jj[sbc.__parport_register_driverasbuh1hhjqubj)}(h h]h }(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjqubj%)}(hj(h]h*}(hjhhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hjqubh)}(hdrvh]hdrv}(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjqubeh}(h]h ]h"]h$]h&]noemphj j uh1jhjmubj)}(hstruct module *ownerh](j)}(hjh]hstruct}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubh)}(hhh]h)}(hmoduleh]hmodule}(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetjmodnameN classnameNjj )}j]jc.__parport_register_driverasbuh1hhjubj)}(h h]h }(hj#hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj%)}(hj(h]h*}(hj1hhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hjubh)}(hownerh]howner}(hj>hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubeh}(h]h ]h"]h$]h&]noemphj j uh1jhjmubj)}(hconst char *mod_nameh](j)}(hjh]hconst}(hjWhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjSubj)}(h h]h }(hjdhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjSubj)}(hcharh]hchar}(hjrhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjSubj)}(h h]h }(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjSubj%)}(hj(h]h*}(hjhhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hjSubh)}(hmod_nameh]hmod_name}(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjSubeh}(h]h ]h"]h$]h&]noemphj j uh1jhjmubeh}(h]h ]h"]h$]h&]j j uh1jhj4hhhjFhKubeh}(h]h ]h"]h$]h&]j j juh1hjjhj0hhhjFhKubah}(h]j+ah ](jjeh"]h$]h&]jj )j!huh1hhjFhKhj-hhubj#)}(hhh]j<)}(h®ister a parallel port device driverh]h®ister a parallel port device driver}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chKhjhhubah}(h]h ]h"]h$]h&]uh1j"hj-hhhjFhKubeh}(h]h ](j0functioneh"]h$]h&]j5j0j6jj7jj8j9j:uh1hhhhhhNhNubjs)}(hX-**Parameters** ``struct parport_driver *drv`` structure describing the driver ``struct module *owner`` owner module of drv ``const char *mod_name`` module name string **Description** This can be called by a parallel port device driver in order to receive notifications about ports being found in the system, as well as ports no longer available. If devmodel is true then the new device model is used for registration. The **drv** structure is allocated by the caller and must not be deallocated until after calling parport_unregister_driver(). If using the non device model: The driver's attach() function may block. The port that attach() is given will be valid for the duration of the callback, but if the driver wants to take a copy of the pointer it must call parport_get_port() to do so. Calling parport_register_device() on that port will do this for you. The driver's detach() function may block. The port that detach() is given will be valid for the duration of the callback, but if the driver wants to take a copy of the pointer it must call parport_get_port() to do so. Returns 0 on success. The non device model will always succeeds. but the new device model can fail and will return the error code.h](j<)}(h**Parameters**h]j})}(hjh]h Parameters}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chKhjubj)}(hhh](j)}(h?``struct parport_driver *drv`` structure describing the driver h](j)}(h``struct parport_driver *drv``h]jB)}(hjh]hstruct parport_driver *drv}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhjubah}(h]h ]h"]h$]h&]uh1jh`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chKhjubj)}(hhh]j<)}(hstructure describing the driverh]hstructure describing the driver}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hjhKhjubah}(h]h ]h"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]uh1jhjhKhjubj)}(h-``struct module *owner`` owner module of drv h](j)}(h``struct module *owner``h]jB)}(hj?h]hstruct module *owner}(hjAhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhj=ubah}(h]h ]h"]h$]h&]uh1jh`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chKhj9ubj)}(hhh]j<)}(howner module of drvh]howner module of drv}(hjXhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hjThKhjUubah}(h]h ]h"]h$]h&]uh1jhj9ubeh}(h]h ]h"]h$]h&]uh1jhjThKhjubj)}(h,``const char *mod_name`` module name string h](j)}(h``const char *mod_name``h]jB)}(hjxh]hconst char *mod_name}(hjzhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhjvubah}(h]h ]h"]h$]h&]uh1jh`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chKhjrubj)}(hhh]j<)}(hmodule name stringh]hmodule name string}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hjhKhjubah}(h]h ]h"]h$]h&]uh1jhjrubeh}(h]h ]h"]h$]h&]uh1jhjhKhjubeh}(h]h ]h"]h$]h&]uh1jhjubj<)}(h**Description**h]j})}(hjh]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chKhjubjX)}(hX This can be called by a parallel port device driver in order to receive notifications about ports being found in the system, as well as ports no longer available. If devmodel is true then the new device model is used for registration. The **drv** structure is allocated by the caller and must not be deallocated until after calling parport_unregister_driver(). If using the non device model: The driver's attach() function may block. The port that attach() is given will be valid for the duration of the callback, but if the driver wants to take a copy of the pointer it must call parport_get_port() to do so. Calling parport_register_device() on that port will do this for you. The driver's detach() function may block. The port that detach() is given will be valid for the duration of the callback, but if the driver wants to take a copy of the pointer it must call parport_get_port() to do so. Returns 0 on success. The non device model will always succeeds. but the new device model can fail and will return the error code.h](j<)}(hThis can be called by a parallel port device driver in order to receive notifications about ports being found in the system, as well as ports no longer available.h]hThis can be called by a parallel port device driver in order to receive notifications about ports being found in the system, as well as ports no longer available.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chKhjubj<)}(hGIf devmodel is true then the new device model is used for registration.h]hGIf devmodel is true then the new device model is used for registration.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chKhjubj<)}(h}The **drv** structure is allocated by the caller and must not be deallocated until after calling parport_unregister_driver().h](hThe }(hjhhhNhNubj})}(h**drv**h]hdrv}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjubhr structure is allocated by the caller and must not be deallocated until after calling parport_unregister_driver().}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chKhjubj<)}(hX?If using the non device model: The driver's attach() function may block. The port that attach() is given will be valid for the duration of the callback, but if the driver wants to take a copy of the pointer it must call parport_get_port() to do so. Calling parport_register_device() on that port will do this for you.h]hXAIf using the non device model: The driver’s attach() function may block. The port that attach() is given will be valid for the duration of the callback, but if the driver wants to take a copy of the pointer it must call parport_get_port() to do so. Calling parport_register_device() on that port will do this for you.}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chKhjubj<)}(hThe driver's detach() function may block. The port that detach() is given will be valid for the duration of the callback, but if the driver wants to take a copy of the pointer it must call parport_get_port() to do so.h]hThe driver’s detach() function may block. The port that detach() is given will be valid for the duration of the callback, but if the driver wants to take a copy of the pointer it must call parport_get_port() to do so.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMhjubj<)}(hReturns 0 on success. The non device model will always succeeds. but the new device model can fail and will return the error code.h]hReturns 0 on success. The non device model will always succeeds. but the new device model can fail and will return the error code.}(hj*hhhNhNubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMhjubeh}(h]h ]h"]h$]h&]uh1jWhjhKhjubeh}(h]h ] kernelindentah"]h$]h&]uh1jrhhhhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](h،&parport_unregister_driver (C function)c.parport_unregister_driverhNtauh1hhhhhhNhNubh)}(hhh](h)}(h;void parport_unregister_driver (struct parport_driver *drv)h]h)}(h:void parport_unregister_driver(struct parport_driver *drv)h](j)}(hvoidh]hvoid}(hj_hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj[hhh`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chM:ubj)}(h h]h }(hjnhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj[hhhjmhM:ubh)}(hparport_unregister_driverh]h)}(hparport_unregister_driverh]hparport_unregister_driver}(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj|ubah}(h]h ](jjeh"]h$]h&]j j uh1hhj[hhhjmhM:ubj)}(h(struct parport_driver *drv)h]j)}(hstruct parport_driver *drvh](j)}(hjh]hstruct}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubh)}(hhh]h)}(hparport_driverh]hparport_driver}(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetjmodnameN classnameNjj )}j]j)}jjsbc.parport_unregister_driverasbuh1hhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj%)}(hj(h]h*}(hjhhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hjubh)}(hdrvh]hdrv}(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubeh}(h]h ]h"]h$]h&]noemphj j uh1jhjubah}(h]h ]h"]h$]h&]j j uh1jhj[hhhjmhM:ubeh}(h]h ]h"]h$]h&]j j juh1hjjhjWhhhjmhM:ubah}(h]jRah ](jjeh"]h$]h&]jj )j!huh1hhjmhM:hjThhubj#)}(hhh]j<)}(h(deregister a parallel port device driverh]h(deregister a parallel port device driver}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chM:hjhhubah}(h]h ]h"]h$]h&]uh1j"hjThhhjmhM:ubeh}(h]h ](j0functioneh"]h$]h&]j5j0j6j7j7j7j8j9j:uh1hhhhhhNhNubjs)}(hXb**Parameters** ``struct parport_driver *drv`` structure describing the driver that was given to parport_register_driver() **Description** This should be called by a parallel port device driver that has registered itself using parport_register_driver() when it is about to be unloaded. When it returns, the driver's attach() routine will no longer be called, and for each port that attach() was called for, the detach() routine will have been called. All the driver's attach() and detach() calls are guaranteed to have finished by the time this function returns.h](j<)}(h**Parameters**h]j})}(hjAh]h Parameters}(hjChhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj?ubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chM>hj;ubj)}(hhh]j)}(hk``struct parport_driver *drv`` structure describing the driver that was given to parport_register_driver() h](j)}(h``struct parport_driver *drv``h]jB)}(hj`h]hstruct parport_driver *drv}(hjbhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhj^ubah}(h]h ]h"]h$]h&]uh1jh`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chM<hjZubj)}(hhh]j<)}(hKstructure describing the driver that was given to parport_register_driver()h]hKstructure describing the driver that was given to parport_register_driver()}(hjyhhhNhNubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chM;hjvubah}(h]h ]h"]h$]h&]uh1jhjZubeh}(h]h ]h"]h$]h&]uh1jhjuhM<hjWubah}(h]h ]h"]h$]h&]uh1jhj;ubj<)}(h**Description**h]j})}(hjh]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chM>hj;ubjX)}(hXThis should be called by a parallel port device driver that has registered itself using parport_register_driver() when it is about to be unloaded. When it returns, the driver's attach() routine will no longer be called, and for each port that attach() was called for, the detach() routine will have been called. All the driver's attach() and detach() calls are guaranteed to have finished by the time this function returns.h](j<)}(hThis should be called by a parallel port device driver that has registered itself using parport_register_driver() when it is about to be unloaded.h]hThis should be called by a parallel port device driver that has registered itself using parport_register_driver() when it is about to be unloaded.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chM=hjubj<)}(hWhen it returns, the driver's attach() routine will no longer be called, and for each port that attach() was called for, the detach() routine will have been called.h]hWhen it returns, the driver’s attach() routine will no longer be called, and for each port that attach() was called for, the detach() routine will have been called.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMAhjubj<)}(hoAll the driver's attach() and detach() calls are guaranteed to have finished by the time this function returns.h]hqAll the driver’s attach() and detach() calls are guaranteed to have finished by the time this function returns.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMEhjubeh}(h]h ]h"]h$]h&]uh1jWhjhM=hj;ubeh}(h]h ] kernelindentah"]h$]h&]uh1jrhhhhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](h،parport_get_port (C function)c.parport_get_porthNtauh1hhhhhhNhNubh)}(hhh](h)}(h8struct parport * parport_get_port (struct parport *port)h]h)}(h6struct parport *parport_get_port(struct parport *port)h](j)}(hjh]hstruct}(hj hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjhhh`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMgubj)}(h h]h }(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjhhhjhMgubh)}(hhh]h)}(hparporth]hparport}(hj(hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj%ubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetj*modnameN classnameNjj )}j]j)}jparport_get_portsbc.parport_get_portasbuh1hhjhhhjhMgubj)}(h h]h }(hjIhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjhhhjhMgubj%)}(hj(h]h*}(hjWhhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hjhhhjhMgubh)}(hparport_get_porth]h)}(hjFh]hparport_get_port}(hjhhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjdubah}(h]h ](jjeh"]h$]h&]j j uh1hhjhhhjhMgubj)}(h(struct parport *port)h]j)}(hstruct parport *porth](j)}(hjh]hstruct}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubh)}(hhh]h)}(hparporth]hparport}(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetjmodnameN classnameNjj )}j]jDc.parport_get_portasbuh1hhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj%)}(hj(h]h*}(hjhhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hjubh)}(hporth]hport}(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubeh}(h]h ]h"]h$]h&]noemphj j uh1jhj{ubah}(h]h ]h"]h$]h&]j j uh1jhjhhhjhMgubeh}(h]h ]h"]h$]h&]j j juh1hjjhjhhhjhMgubah}(h]jah ](jjeh"]h$]h&]jj )j!huh1hhjhMghjhhubj#)}(hhh]j<)}(h"increment a port's reference counth]h$increment a port’s reference count}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMghjhhubah}(h]h ]h"]h$]h&]uh1j"hjhhhjhMgubeh}(h]h ](j0functioneh"]h$]h&]j5j0j6jj7jj8j9j:uh1hhhhhhNhNubjs)}(h**Parameters** ``struct parport *port`` the port **Description** This ensures that a struct parport pointer remains valid until the matching parport_put_port() call.h](j<)}(h**Parameters**h]j})}(hj&h]h Parameters}(hj(hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj$ubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMkhj ubj)}(hhh]j)}(h"``struct parport *port`` the port h](j)}(h``struct parport *port``h]jB)}(hjEh]hstruct parport *port}(hjGhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhjCubah}(h]h ]h"]h$]h&]uh1jh`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMhhj?ubj)}(hhh]j<)}(hthe porth]hthe port}(hj^hhhNhNubah}(h]h ]h"]h$]h&]uh1j;hjZhMhhj[ubah}(h]h ]h"]h$]h&]uh1jhj?ubeh}(h]h ]h"]h$]h&]uh1jhjZhMhhj<ubah}(h]h ]h"]h$]h&]uh1jhj ubj<)}(h**Description**h]j})}(hjh]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj~ubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMjhj ubjX)}(hdThis ensures that a struct parport pointer remains valid until the matching parport_put_port() call.h]j<)}(hdThis ensures that a struct parport pointer remains valid until the matching parport_put_port() call.h]hdThis ensures that a struct parport pointer remains valid until the matching parport_put_port() call.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMihjubah}(h]h ]h"]h$]h&]uh1jWhjhMihj ubeh}(h]h ] kernelindentah"]h$]h&]uh1jrhhhhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](h،parport_put_port (C function)c.parport_put_porthNtauh1hhhhhhNhNubh)}(hhh](h)}(h,void parport_put_port (struct parport *port)h]h)}(h+void parport_put_port(struct parport *port)h](j)}(hvoidh]hvoid}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjhhh`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chM}ubj)}(h h]h }(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjhhhjhM}ubh)}(hparport_put_porth]h)}(hparport_put_porth]hparport_put_port}(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubah}(h]h ](jjeh"]h$]h&]j j uh1hhjhhhjhM}ubj)}(h(struct parport *port)h]j)}(hstruct parport *porth](j)}(hjh]hstruct}(hj hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubh)}(hhh]h)}(hparporth]hparport}(hj*hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj'ubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetj,modnameN classnameNjj )}j]j)}jjsbc.parport_put_portasbuh1hhjubj)}(h h]h }(hjJhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj%)}(hj(h]h*}(hjXhhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hjubh)}(hporth]hport}(hjehhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubeh}(h]h ]h"]h$]h&]noemphj j uh1jhjubah}(h]h ]h"]h$]h&]j j uh1jhjhhhjhM}ubeh}(h]h ]h"]h$]h&]j j juh1hjjhjhhhjhM}ubah}(h]jah ](jjeh"]h$]h&]jj )j!huh1hhjhM}hjhhubj#)}(hhh]j<)}(h"decrement a port's reference counth]h$decrement a port’s reference count}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chM}hjhhubah}(h]h ]h"]h$]h&]uh1j"hjhhhjhM}ubeh}(h]h ](j0functioneh"]h$]h&]j5j0j6jj7jj8j9j:uh1hhhhhhNhNubjs)}(hX **Parameters** ``struct parport *port`` the port **Description** This should be called once for each call to parport_get_port(), once the port is no longer needed. When the reference count reaches zero (port is no longer used), free_port is called.h](j<)}(h**Parameters**h]j})}(hjh]h Parameters}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMhjubj)}(hhh]j)}(h"``struct parport *port`` the port h](j)}(h``struct parport *port``h]jB)}(hjh]hstruct parport *port}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhjubah}(h]h ]h"]h$]h&]uh1jh`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chM~hjubj)}(hhh]j<)}(hthe porth]hthe port}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hjhM~hjubah}(h]h ]h"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]uh1jhjhM~hjubah}(h]h ]h"]h$]h&]uh1jhjubj<)}(h**Description**h]j})}(hj h]h Description}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj ubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMhjubjX)}(hThis should be called once for each call to parport_get_port(), once the port is no longer needed. When the reference count reaches zero (port is no longer used), free_port is called.h]j<)}(hThis should be called once for each call to parport_get_port(), once the port is no longer needed. When the reference count reaches zero (port is no longer used), free_port is called.h]hThis should be called once for each call to parport_get_port(), once the port is no longer needed. When the reference count reaches zero (port is no longer used), free_port is called.}(hj%hhhNhNubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMhj!ubah}(h]h ]h"]h$]h&]uh1jWhj3hMhjubeh}(h]h ] kernelindentah"]h$]h&]uh1jrhhhhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](h،"parport_register_port (C function)c.parport_register_porthNtauh1hhhhhhNhNubh)}(hhh](h)}(hmstruct parport * parport_register_port (unsigned long base, int irq, int dma, struct parport_operations *ops)h]h)}(hkstruct parport *parport_register_port(unsigned long base, int irq, int dma, struct parport_operations *ops)h](j)}(hjh]hstruct}(hjZhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjVhhh`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMubj)}(h h]h }(hjhhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjVhhhjghMubh)}(hhh]h)}(hparporth]hparport}(hjyhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjvubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetj{modnameN classnameNjj )}j]j)}jparport_register_portsbc.parport_register_portasbuh1hhjVhhhjghMubj)}(h h]h }(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjVhhhjghMubj%)}(hj(h]h*}(hjhhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hjVhhhjghMubh)}(hparport_register_porth]h)}(hjh]hparport_register_port}(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubah}(h]h ](jjeh"]h$]h&]j j uh1hhjVhhhjghMubj)}(hF(unsigned long base, int irq, int dma, struct parport_operations *ops)h](j)}(hunsigned long baseh](j)}(hunsignedh]hunsigned}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(hlongh]hlong}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubh)}(hbaseh]hbase}(hj hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubeh}(h]h ]h"]h$]h&]noemphj j uh1jhjubj)}(hint irqh](j)}(hinth]hint}(hj%hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj!ubj)}(h h]h }(hj3hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj!ubh)}(hirqh]hirq}(hjAhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj!ubeh}(h]h ]h"]h$]h&]noemphj j uh1jhjubj)}(hint dmah](j)}(hinth]hint}(hjZhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjVubj)}(h h]h }(hjhhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjVubh)}(hdmah]hdma}(hjvhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjVubeh}(h]h ]h"]h$]h&]noemphj j uh1jhjubj)}(hstruct parport_operations *opsh](j)}(hjh]hstruct}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubh)}(hhh]h)}(hparport_operationsh]hparport_operations}(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetjmodnameN classnameNjj )}j]jc.parport_register_portasbuh1hhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj%)}(hj(h]h*}(hjhhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hjubh)}(hopsh]hops}(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubeh}(h]h ]h"]h$]h&]noemphj j uh1jhjubeh}(h]h ]h"]h$]h&]j j uh1jhjVhhhjghMubeh}(h]h ]h"]h$]h&]j j juh1hjjhjRhhhjghMubah}(h]jMah ](jjeh"]h$]h&]jj )j!huh1hhjghMhjOhhubj#)}(hhh]j<)}(hregister a parallel porth]hregister a parallel port}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMhj hhubah}(h]h ]h"]h$]h&]uh1j"hjOhhhjghMubeh}(h]h ](j0functioneh"]h$]h&]j5j0j6j( j7j( j8j9j:uh1hhhhhhNhNubjs)}(hX**Parameters** ``unsigned long base`` base I/O address ``int irq`` IRQ line ``int dma`` DMA channel ``struct parport_operations *ops`` pointer to the port driver's port operations structure **Description** When a parallel port (lowlevel) driver finds a port that should be made available to parallel port device drivers, it should call parport_register_port(). The **base**, **irq**, and **dma** parameters are for the convenience of port drivers, and for ports where they aren't meaningful needn't be set to anything special. They can be altered afterwards by adjusting the relevant members of the parport structure that is returned and represents the port. They should not be tampered with after calling parport_announce_port, however. If there are parallel port device drivers in the system that have registered themselves using parport_register_driver(), they are not told about the port at this time; that is done by parport_announce_port(). The **ops** structure is allocated by the caller, and must not be deallocated before calling parport_remove_port(). If there is no memory to allocate a new parport structure, this function will return ``NULL``.h](j<)}(h**Parameters**h]j})}(hj2 h]h Parameters}(hj4 hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj0 ubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMhj, ubj)}(hhh](j)}(h(``unsigned long base`` base I/O address h](j)}(h``unsigned long base``h]jB)}(hjQ h]hunsigned long base}(hjS hhhNhNubah}(h]h ]h"]h$]h&]uh1jAhjO ubah}(h]h ]h"]h$]h&]uh1jh`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMhjK ubj)}(hhh]j<)}(hbase I/O addressh]hbase I/O address}(hjj hhhNhNubah}(h]h ]h"]h$]h&]uh1j;hjf hMhjg ubah}(h]h ]h"]h$]h&]uh1jhjK ubeh}(h]h ]h"]h$]h&]uh1jhjf hMhjH ubj)}(h``int irq`` IRQ line h](j)}(h ``int irq``h]jB)}(hj h]hint irq}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jAhj ubah}(h]h ]h"]h$]h&]uh1jh`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMhj ubj)}(hhh]j<)}(hIRQ lineh]hIRQ line}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1j;hj hMhj ubah}(h]h ]h"]h$]h&]uh1jhj ubeh}(h]h ]h"]h$]h&]uh1jhj hMhjH ubj)}(h``int dma`` DMA channel h](j)}(h ``int dma``h]jB)}(hj h]hint dma}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jAhj ubah}(h]h ]h"]h$]h&]uh1jh`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMhj ubj)}(hhh]j<)}(h DMA channelh]h DMA channel}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1j;hj hMhj ubah}(h]h ]h"]h$]h&]uh1jhj ubeh}(h]h ]h"]h$]h&]uh1jhj hMhjH ubj)}(hZ``struct parport_operations *ops`` pointer to the port driver's port operations structure h](j)}(h"``struct parport_operations *ops``h]jB)}(hj h]hstruct parport_operations *ops}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jAhj ubah}(h]h ]h"]h$]h&]uh1jh`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMhj ubj)}(hhh]j<)}(h6pointer to the port driver's port operations structureh]h8pointer to the port driver’s port operations structure}(hj!hhhNhNubah}(h]h ]h"]h$]h&]uh1j;hj!hMhj!ubah}(h]h ]h"]h$]h&]uh1jhj ubeh}(h]h ]h"]h$]h&]uh1jhj!hMhjH ubeh}(h]h ]h"]h$]h&]uh1jhj, ubj<)}(h**Description**h]j})}(hj7!h]h Description}(hj9!hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj5!ubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMhj, ubjX)}(hXWhen a parallel port (lowlevel) driver finds a port that should be made available to parallel port device drivers, it should call parport_register_port(). The **base**, **irq**, and **dma** parameters are for the convenience of port drivers, and for ports where they aren't meaningful needn't be set to anything special. They can be altered afterwards by adjusting the relevant members of the parport structure that is returned and represents the port. They should not be tampered with after calling parport_announce_port, however. If there are parallel port device drivers in the system that have registered themselves using parport_register_driver(), they are not told about the port at this time; that is done by parport_announce_port(). The **ops** structure is allocated by the caller, and must not be deallocated before calling parport_remove_port(). If there is no memory to allocate a new parport structure, this function will return ``NULL``.h](j<)}(hXWhen a parallel port (lowlevel) driver finds a port that should be made available to parallel port device drivers, it should call parport_register_port(). The **base**, **irq**, and **dma** parameters are for the convenience of port drivers, and for ports where they aren't meaningful needn't be set to anything special. They can be altered afterwards by adjusting the relevant members of the parport structure that is returned and represents the port. They should not be tampered with after calling parport_announce_port, however.h](hWhen a parallel port (lowlevel) driver finds a port that should be made available to parallel port device drivers, it should call parport_register_port(). The }(hjQ!hhhNhNubj})}(h**base**h]hbase}(hjY!hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjQ!ubh, }(hjQ!hhhNhNubj})}(h**irq**h]hirq}(hjk!hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjQ!ubh, and }(hjQ!hhhNhNubj})}(h**dma**h]hdma}(hj}!hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjQ!ubhX\ parameters are for the convenience of port drivers, and for ports where they aren’t meaningful needn’t be set to anything special. They can be altered afterwards by adjusting the relevant members of the parport structure that is returned and represents the port. They should not be tampered with after calling parport_announce_port, however.}(hjQ!hhhNhNubeh}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMhjM!ubj<)}(hIf there are parallel port device drivers in the system that have registered themselves using parport_register_driver(), they are not told about the port at this time; that is done by parport_announce_port().h]hIf there are parallel port device drivers in the system that have registered themselves using parport_register_driver(), they are not told about the port at this time; that is done by parport_announce_port().}(hj!hhhNhNubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMhjM!ubj<)}(hsThe **ops** structure is allocated by the caller, and must not be deallocated before calling parport_remove_port().h](hThe }(hj!hhhNhNubj})}(h**ops**h]hops}(hj!hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj!ubhh structure is allocated by the caller, and must not be deallocated before calling parport_remove_port().}(hj!hhhNhNubeh}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMhjM!ubj<)}(h^If there is no memory to allocate a new parport structure, this function will return ``NULL``.h](hUIf there is no memory to allocate a new parport structure, this function will return }(hj!hhhNhNubjB)}(h``NULL``h]hNULL}(hj!hhhNhNubah}(h]h ]h"]h$]h&]uh1jAhj!ubh.}(hj!hhhNhNubeh}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMhjM!ubeh}(h]h ]h"]h$]h&]uh1jWhj!hMhj, ubeh}(h]h ] kernelindentah"]h$]h&]uh1jrhhhhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](h،"parport_announce_port (C function)c.parport_announce_porthNtauh1hhhhhhNhNubh)}(hhh](h)}(h1void parport_announce_port (struct parport *port)h]h)}(h0void parport_announce_port(struct parport *port)h](j)}(hvoidh]hvoid}(hj "hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj "hhh`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMubj)}(h h]h }(hj"hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj "hhhj"hMubh)}(hparport_announce_porth]h)}(hparport_announce_porth]hparport_announce_port}(hj."hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj*"ubah}(h]h ](jjeh"]h$]h&]j j uh1hhj "hhhj"hMubj)}(h(struct parport *port)h]j)}(hstruct parport *porth](j)}(hjh]hstruct}(hjJ"hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjF"ubj)}(h h]h }(hjW"hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjF"ubh)}(hhh]h)}(hparporth]hparport}(hjh"hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhje"ubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetjj"modnameN classnameNjj )}j]j)}jj0"sbc.parport_announce_portasbuh1hhjF"ubj)}(h h]h }(hj"hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjF"ubj%)}(hj(h]h*}(hj"hhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hjF"ubh)}(hporth]hport}(hj"hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjF"ubeh}(h]h ]h"]h$]h&]noemphj j uh1jhjB"ubah}(h]h ]h"]h$]h&]j j uh1jhj "hhhj"hMubeh}(h]h ]h"]h$]h&]j j juh1hjjhj"hhhj"hMubah}(h]j"ah ](jjeh"]h$]h&]jj )j!huh1hhj"hMhj"hhubj#)}(hhh]j<)}(h)tell device drivers about a parallel porth]h)tell device drivers about a parallel port}(hj"hhhNhNubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMhj"hhubah}(h]h ]h"]h$]h&]uh1j"hj"hhhj"hMubeh}(h]h ](j0functioneh"]h$]h&]j5j0j6j"j7j"j8j9j:uh1hhhhhhNhNubjs)}(hX**Parameters** ``struct parport *port`` parallel port to announce **Description** After a port driver has registered a parallel port with parport_register_port, and performed any necessary initialisation or adjustments, it should call parport_announce_port() in order to notify all device drivers that have called parport_register_driver(). Their attach() functions will be called, with **port** as the parameter.h](j<)}(h**Parameters**h]j})}(hj"h]h Parameters}(hj"hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj"ubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMhj"ubj)}(hhh]j)}(h3``struct parport *port`` parallel port to announce h](j)}(h``struct parport *port``h]jB)}(hj#h]hstruct parport *port}(hj#hhhNhNubah}(h]h ]h"]h$]h&]uh1jAhj #ubah}(h]h ]h"]h$]h&]uh1jh`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMhj#ubj)}(hhh]j<)}(hparallel port to announceh]hparallel port to announce}(hj'#hhhNhNubah}(h]h ]h"]h$]h&]uh1j;hj##hMhj$#ubah}(h]h ]h"]h$]h&]uh1jhj#ubeh}(h]h ]h"]h$]h&]uh1jhj##hMhj#ubah}(h]h ]h"]h$]h&]uh1jhj"ubj<)}(h**Description**h]j})}(hjI#h]h Description}(hjK#hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjG#ubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMhj"ubjX)}(hXLAfter a port driver has registered a parallel port with parport_register_port, and performed any necessary initialisation or adjustments, it should call parport_announce_port() in order to notify all device drivers that have called parport_register_driver(). Their attach() functions will be called, with **port** as the parameter.h]j<)}(hXLAfter a port driver has registered a parallel port with parport_register_port, and performed any necessary initialisation or adjustments, it should call parport_announce_port() in order to notify all device drivers that have called parport_register_driver(). Their attach() functions will be called, with **port** as the parameter.h](hX2After a port driver has registered a parallel port with parport_register_port, and performed any necessary initialisation or adjustments, it should call parport_announce_port() in order to notify all device drivers that have called parport_register_driver(). Their attach() functions will be called, with }(hjc#hhhNhNubj})}(h**port**h]hport}(hjk#hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjc#ubh as the parameter.}(hjc#hhhNhNubeh}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMhj_#ubah}(h]h ]h"]h$]h&]uh1jWhj#hMhj"ubeh}(h]h ] kernelindentah"]h$]h&]uh1jrhhhhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](h، parport_remove_port (C function)c.parport_remove_porthNtauh1hhhhhhNhNubh)}(hhh](h)}(h/void parport_remove_port (struct parport *port)h]h)}(h.void parport_remove_port(struct parport *port)h](j)}(hvoidh]hvoid}(hj#hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj#hhh`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMubj)}(h h]h }(hj#hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj#hhhj#hMubh)}(hparport_remove_porth]h)}(hparport_remove_porth]hparport_remove_port}(hj#hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj#ubah}(h]h ](jjeh"]h$]h&]j j uh1hhj#hhhj#hMubj)}(h(struct parport *port)h]j)}(hstruct parport *porth](j)}(hjh]hstruct}(hj#hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj#ubj)}(h h]h }(hj#hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj#ubh)}(hhh]h)}(hparporth]hparport}(hj$hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj$ubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetj$modnameN classnameNjj )}j]j)}jj#sbc.parport_remove_portasbuh1hhj#ubj)}(h h]h }(hj%$hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj#ubj%)}(hj(h]h*}(hj3$hhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hj#ubh)}(hporth]hport}(hj@$hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj#ubeh}(h]h ]h"]h$]h&]noemphj j uh1jhj#ubah}(h]h ]h"]h$]h&]j j uh1jhj#hhhj#hMubeh}(h]h ]h"]h$]h&]j j juh1hjjhj#hhhj#hMubah}(h]j#ah ](jjeh"]h$]h&]jj )j!huh1hhj#hMhj#hhubj#)}(hhh]j<)}(hderegister a parallel porth]hderegister a parallel port}(hjj$hhhNhNubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMhjg$hhubah}(h]h ]h"]h$]h&]uh1j"hj#hhhj#hMubeh}(h]h ](j0functioneh"]h$]h&]j5j0j6j$j7j$j8j9j:uh1hhhhhhNhNubjs)}(hX**Parameters** ``struct parport *port`` parallel port to deregister **Description** When a parallel port driver is forcibly unloaded, or a parallel port becomes inaccessible, the port driver must call this function in order to deal with device drivers that still want to use it. The parport structure associated with the port has its operations structure replaced with one containing 'null' operations that return errors or just don't do anything. Any drivers that have registered themselves using parport_register_driver() are notified that the port is no longer accessible by having their detach() routines called with **port** as the parameter.h](j<)}(h**Parameters**h]j})}(hj$h]h Parameters}(hj$hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj$ubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chM hj$ubj)}(hhh]j)}(h5``struct parport *port`` parallel port to deregister h](j)}(h``struct parport *port``h]jB)}(hj$h]hstruct parport *port}(hj$hhhNhNubah}(h]h ]h"]h$]h&]uh1jAhj$ubah}(h]h ]h"]h$]h&]uh1jh`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMhj$ubj)}(hhh]j<)}(hparallel port to deregisterh]hparallel port to deregister}(hj$hhhNhNubah}(h]h ]h"]h$]h&]uh1j;hj$hMhj$ubah}(h]h ]h"]h$]h&]uh1jhj$ubeh}(h]h ]h"]h$]h&]uh1jhj$hMhj$ubah}(h]h ]h"]h$]h&]uh1jhj$ubj<)}(h**Description**h]j})}(hj$h]h Description}(hj$hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj$ubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMhj$ubjX)}(hX5When a parallel port driver is forcibly unloaded, or a parallel port becomes inaccessible, the port driver must call this function in order to deal with device drivers that still want to use it. The parport structure associated with the port has its operations structure replaced with one containing 'null' operations that return errors or just don't do anything. Any drivers that have registered themselves using parport_register_driver() are notified that the port is no longer accessible by having their detach() routines called with **port** as the parameter.h](j<)}(hWhen a parallel port driver is forcibly unloaded, or a parallel port becomes inaccessible, the port driver must call this function in order to deal with device drivers that still want to use it.h]hWhen a parallel port driver is forcibly unloaded, or a parallel port becomes inaccessible, the port driver must call this function in order to deal with device drivers that still want to use it.}(hj%hhhNhNubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMhj$ubj<)}(hThe parport structure associated with the port has its operations structure replaced with one containing 'null' operations that return errors or just don't do anything.h]hThe parport structure associated with the port has its operations structure replaced with one containing ‘null’ operations that return errors or just don’t do anything.}(hj%hhhNhNubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chM#hj$ubj<)}(hAny drivers that have registered themselves using parport_register_driver() are notified that the port is no longer accessible by having their detach() routines called with **port** as the parameter.h](hAny drivers that have registered themselves using parport_register_driver() are notified that the port is no longer accessible by having their detach() routines called with }(hj%hhhNhNubj})}(h**port**h]hport}(hj&%hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj%ubh as the parameter.}(hj%hhhNhNubeh}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chM'hj$ubeh}(h]h ]h"]h$]h&]uh1jWhj%hMhj$ubeh}(h]h ] kernelindentah"]h$]h&]uh1jrhhhhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](h،'parport_register_dev_model (C function)c.parport_register_dev_modelhNtauh1hhhhhhNhNubh)}(hhh](h)}(hstruct pardevice * parport_register_dev_model (struct parport *port, const char *name, const struct pardev_cb *par_dev_cb, int id)h]h)}(hstruct pardevice *parport_register_dev_model(struct parport *port, const char *name, const struct pardev_cb *par_dev_cb, int id)h](j)}(hjh]hstruct}(hje%hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhja%hhh`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMbubj)}(h h]h }(hjs%hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhja%hhhjr%hMbubh)}(hhh]h)}(h pardeviceh]h pardevice}(hj%hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj%ubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetj%modnameN classnameNjj )}j]j)}jparport_register_dev_modelsbc.parport_register_dev_modelasbuh1hhja%hhhjr%hMbubj)}(h h]h }(hj%hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhja%hhhjr%hMbubj%)}(hj(h]h*}(hj%hhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hja%hhhjr%hMbubh)}(hparport_register_dev_modelh]h)}(hj%h]hparport_register_dev_model}(hj%hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj%ubah}(h]h ](jjeh"]h$]h&]j j uh1hhja%hhhjr%hMbubj)}(hT(struct parport *port, const char *name, const struct pardev_cb *par_dev_cb, int id)h](j)}(hstruct parport *porth](j)}(hjh]hstruct}(hj%hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj%ubj)}(h h]h }(hj%hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj%ubh)}(hhh]h)}(hparporth]hparport}(hj%hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj%ubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetj%modnameN classnameNjj )}j]j%c.parport_register_dev_modelasbuh1hhj%ubj)}(h h]h }(hj&hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj%ubj%)}(hj(h]h*}(hj)&hhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hj%ubh)}(hporth]hport}(hj6&hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj%ubeh}(h]h ]h"]h$]h&]noemphj j uh1jhj%ubj)}(hconst char *nameh](j)}(hjh]hconst}(hjO&hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjK&ubj)}(h h]h }(hj\&hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjK&ubj)}(hcharh]hchar}(hjj&hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjK&ubj)}(h h]h }(hjx&hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjK&ubj%)}(hj(h]h*}(hj&hhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hjK&ubh)}(hnameh]hname}(hj&hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjK&ubeh}(h]h ]h"]h$]h&]noemphj j uh1jhj%ubj)}(h"const struct pardev_cb *par_dev_cbh](j)}(hjh]hconst}(hj&hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj&ubj)}(h h]h }(hj&hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj&ubj)}(hjh]hstruct}(hj&hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj&ubj)}(h h]h }(hj&hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj&ubh)}(hhh]h)}(h pardev_cbh]h pardev_cb}(hj&hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj&ubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetj&modnameN classnameNjj )}j]j%c.parport_register_dev_modelasbuh1hhj&ubj)}(h h]h }(hj'hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj&ubj%)}(hj(h]h*}(hj'hhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hj&ubh)}(h par_dev_cbh]h par_dev_cb}(hj'hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj&ubeh}(h]h ]h"]h$]h&]noemphj j uh1jhj%ubj)}(hint idh](j)}(hinth]hint}(hj7'hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj3'ubj)}(h h]h }(hjE'hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj3'ubh)}(hidh]hid}(hjS'hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj3'ubeh}(h]h ]h"]h$]h&]noemphj j uh1jhj%ubeh}(h]h ]h"]h$]h&]j j uh1jhja%hhhjr%hMbubeh}(h]h ]h"]h$]h&]j j juh1hjjhj]%hhhjr%hMbubah}(h]jX%ah ](jjeh"]h$]h&]jj )j!huh1hhjr%hMbhjZ%hhubj#)}(hhh]j<)}(h$register a device on a parallel porth]h$register a device on a parallel port}(hj}'hhhNhNubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMbhjz'hhubah}(h]h ]h"]h$]h&]uh1j"hjZ%hhhjr%hMbubeh}(h]h ](j0functioneh"]h$]h&]j5j0j6j'j7j'j8j9j:uh1hhhhhhNhNubjs)}(hX **Parameters** ``struct parport *port`` port to which the device is attached ``const char *name`` a name to refer to the device ``const struct pardev_cb *par_dev_cb`` struct containing callbacks ``int id`` device number to be given to the device **Description** This function, called by parallel port device drivers, declares that a device is connected to a port, and tells the system all it needs to know. The struct pardev_cb contains pointer to callbacks. preemption callback function, **preempt**, is called when this device driver has claimed access to the port but another device driver wants to use it. It is given, **private**, as its parameter, and should return zero if it is willing for the system to release the port to another driver on its behalf. If it wants to keep control of the port it should return non-zero, and no action will be taken. It is good manners for the driver to try to release the port at the earliest opportunity after its preemption callback rejects a preemption attempt. Note that if a preemption callback is happy for preemption to go ahead, there is no need to release the port; it is done automatically. This function may not block, as it may be called from interrupt context. If the device driver does not support preemption, **preempt** can be ``NULL``. The wake-up ("kick") callback function, **wakeup**, is called when the port is available to be claimed for exclusive access; that is, parport_claim() is guaranteed to succeed when called from inside the wake-up callback function. If the driver wants to claim the port it should do so; otherwise, it need not take any action. This function may not block, as it may be called from interrupt context. If the device driver does not want to be explicitly invited to claim the port in this way, **wakeup** can be ``NULL``. The interrupt handler, **irq_func**, is called when an interrupt arrives from the parallel port. Note that if a device driver wants to use interrupts it should use parport_enable_irq(), and can also check the irq member of the parport structure representing the port. The parallel port (lowlevel) driver is the one that has called request_irq() and whose interrupt handler is called first. This handler does whatever needs to be done to the hardware to acknowledge the interrupt (for PC-style ports there is nothing special to be done). It then tells the IEEE 1284 code about the interrupt, which may involve reacting to an IEEE 1284 event depending on the current IEEE 1284 phase. After this, it calls **irq_func**. Needless to say, **irq_func** will be called from interrupt context, and may not block. The ``PARPORT_DEV_EXCL`` flag is for preventing port sharing, and so should only be used when sharing the port with other device drivers is impossible and would lead to incorrect behaviour. Use it sparingly! Normally, **flags** will be zero. This function returns a pointer to a structure that represents the device on the port, or ``NULL`` if there is not enough memory to allocate space for that structure.h](j<)}(h**Parameters**h]j})}(hj'h]h Parameters}(hj'hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj'ubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMfhj'ubj)}(hhh](j)}(h>``struct parport *port`` port to which the device is attached h](j)}(h``struct parport *port``h]jB)}(hj'h]hstruct parport *port}(hj'hhhNhNubah}(h]h ]h"]h$]h&]uh1jAhj'ubah}(h]h ]h"]h$]h&]uh1jh`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMchj'ubj)}(hhh]j<)}(h$port to which the device is attachedh]h$port to which the device is attached}(hj'hhhNhNubah}(h]h ]h"]h$]h&]uh1j;hj'hMchj'ubah}(h]h ]h"]h$]h&]uh1jhj'ubeh}(h]h ]h"]h$]h&]uh1jhj'hMchj'ubj)}(h3``const char *name`` a name to refer to the device h](j)}(h``const char *name``h]jB)}(hj'h]hconst char *name}(hj'hhhNhNubah}(h]h ]h"]h$]h&]uh1jAhj'ubah}(h]h ]h"]h$]h&]uh1jh`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMdhj'ubj)}(hhh]j<)}(ha name to refer to the deviceh]ha name to refer to the device}(hj(hhhNhNubah}(h]h ]h"]h$]h&]uh1j;hj (hMdhj (ubah}(h]h ]h"]h$]h&]uh1jhj'ubeh}(h]h ]h"]h$]h&]uh1jhj (hMdhj'ubj)}(hC``const struct pardev_cb *par_dev_cb`` struct containing callbacks h](j)}(h&``const struct pardev_cb *par_dev_cb``h]jB)}(hj0(h]h"const struct pardev_cb *par_dev_cb}(hj2(hhhNhNubah}(h]h ]h"]h$]h&]uh1jAhj.(ubah}(h]h ]h"]h$]h&]uh1jh`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMehj*(ubj)}(hhh]j<)}(hstruct containing callbacksh]hstruct containing callbacks}(hjI(hhhNhNubah}(h]h ]h"]h$]h&]uh1j;hjE(hMehjF(ubah}(h]h ]h"]h$]h&]uh1jhj*(ubeh}(h]h ]h"]h$]h&]uh1jhjE(hMehj'ubj)}(h3``int id`` device number to be given to the device h](j)}(h ``int id``h]jB)}(hji(h]hint id}(hjk(hhhNhNubah}(h]h ]h"]h$]h&]uh1jAhjg(ubah}(h]h ]h"]h$]h&]uh1jh`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMfhjc(ubj)}(hhh]j<)}(h'device number to be given to the deviceh]h'device number to be given to the device}(hj(hhhNhNubah}(h]h ]h"]h$]h&]uh1j;hj~(hMfhj(ubah}(h]h ]h"]h$]h&]uh1jhjc(ubeh}(h]h ]h"]h$]h&]uh1jhj~(hMfhj'ubeh}(h]h ]h"]h$]h&]uh1jhj'ubj<)}(h**Description**h]j})}(hj(h]h Description}(hj(hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj(ubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMhhj'ubjX)}(hX This function, called by parallel port device drivers, declares that a device is connected to a port, and tells the system all it needs to know. The struct pardev_cb contains pointer to callbacks. preemption callback function, **preempt**, is called when this device driver has claimed access to the port but another device driver wants to use it. It is given, **private**, as its parameter, and should return zero if it is willing for the system to release the port to another driver on its behalf. If it wants to keep control of the port it should return non-zero, and no action will be taken. It is good manners for the driver to try to release the port at the earliest opportunity after its preemption callback rejects a preemption attempt. Note that if a preemption callback is happy for preemption to go ahead, there is no need to release the port; it is done automatically. This function may not block, as it may be called from interrupt context. If the device driver does not support preemption, **preempt** can be ``NULL``. The wake-up ("kick") callback function, **wakeup**, is called when the port is available to be claimed for exclusive access; that is, parport_claim() is guaranteed to succeed when called from inside the wake-up callback function. If the driver wants to claim the port it should do so; otherwise, it need not take any action. This function may not block, as it may be called from interrupt context. If the device driver does not want to be explicitly invited to claim the port in this way, **wakeup** can be ``NULL``. The interrupt handler, **irq_func**, is called when an interrupt arrives from the parallel port. Note that if a device driver wants to use interrupts it should use parport_enable_irq(), and can also check the irq member of the parport structure representing the port. The parallel port (lowlevel) driver is the one that has called request_irq() and whose interrupt handler is called first. This handler does whatever needs to be done to the hardware to acknowledge the interrupt (for PC-style ports there is nothing special to be done). It then tells the IEEE 1284 code about the interrupt, which may involve reacting to an IEEE 1284 event depending on the current IEEE 1284 phase. After this, it calls **irq_func**. Needless to say, **irq_func** will be called from interrupt context, and may not block. The ``PARPORT_DEV_EXCL`` flag is for preventing port sharing, and so should only be used when sharing the port with other device drivers is impossible and would lead to incorrect behaviour. Use it sparingly! Normally, **flags** will be zero. This function returns a pointer to a structure that represents the device on the port, or ``NULL`` if there is not enough memory to allocate space for that structure.h](j<)}(hThis function, called by parallel port device drivers, declares that a device is connected to a port, and tells the system all it needs to know.h]hThis function, called by parallel port device drivers, declares that a device is connected to a port, and tells the system all it needs to know.}(hj(hhhNhNubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMghj(ubj<)}(hXxThe struct pardev_cb contains pointer to callbacks. preemption callback function, **preempt**, is called when this device driver has claimed access to the port but another device driver wants to use it. It is given, **private**, as its parameter, and should return zero if it is willing for the system to release the port to another driver on its behalf. If it wants to keep control of the port it should return non-zero, and no action will be taken. It is good manners for the driver to try to release the port at the earliest opportunity after its preemption callback rejects a preemption attempt. Note that if a preemption callback is happy for preemption to go ahead, there is no need to release the port; it is done automatically. This function may not block, as it may be called from interrupt context. If the device driver does not support preemption, **preempt** can be ``NULL``.h](hRThe struct pardev_cb contains pointer to callbacks. preemption callback function, }(hj(hhhNhNubj})}(h **preempt**h]hpreempt}(hj(hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj(ubh|, is called when this device driver has claimed access to the port but another device driver wants to use it. It is given, }(hj(hhhNhNubj})}(h **private**h]hprivate}(hj(hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj(ubhXx, as its parameter, and should return zero if it is willing for the system to release the port to another driver on its behalf. If it wants to keep control of the port it should return non-zero, and no action will be taken. It is good manners for the driver to try to release the port at the earliest opportunity after its preemption callback rejects a preemption attempt. Note that if a preemption callback is happy for preemption to go ahead, there is no need to release the port; it is done automatically. This function may not block, as it may be called from interrupt context. If the device driver does not support preemption, }(hj(hhhNhNubj})}(h **preempt**h]hpreempt}(hj(hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj(ubh can be }(hj(hhhNhNubjB)}(h``NULL``h]hNULL}(hj )hhhNhNubah}(h]h ]h"]h$]h&]uh1jAhj(ubh.}(hj(hhhNhNubeh}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMkhj(ubj<)}(hXThe wake-up ("kick") callback function, **wakeup**, is called when the port is available to be claimed for exclusive access; that is, parport_claim() is guaranteed to succeed when called from inside the wake-up callback function. If the driver wants to claim the port it should do so; otherwise, it need not take any action. This function may not block, as it may be called from interrupt context. If the device driver does not want to be explicitly invited to claim the port in this way, **wakeup** can be ``NULL``.h](h,The wake-up (“kick”) callback function, }(hj$)hhhNhNubj})}(h **wakeup**h]hwakeup}(hj,)hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj$)ubhX, is called when the port is available to be claimed for exclusive access; that is, parport_claim() is guaranteed to succeed when called from inside the wake-up callback function. If the driver wants to claim the port it should do so; otherwise, it need not take any action. This function may not block, as it may be called from interrupt context. If the device driver does not want to be explicitly invited to claim the port in this way, }(hj$)hhhNhNubj})}(h **wakeup**h]hwakeup}(hj>)hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj$)ubh can be }(hj$)hhhNhNubjB)}(h``NULL``h]hNULL}(hjP)hhhNhNubah}(h]h ]h"]h$]h&]uh1jAhj$)ubh.}(hj$)hhhNhNubeh}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMzhj(ubj<)}(hX The interrupt handler, **irq_func**, is called when an interrupt arrives from the parallel port. Note that if a device driver wants to use interrupts it should use parport_enable_irq(), and can also check the irq member of the parport structure representing the port.h](hThe interrupt handler, }(hji)hhhNhNubj})}(h **irq_func**h]hirq_func}(hjq)hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hji)ubh, is called when an interrupt arrives from the parallel port. Note that if a device driver wants to use interrupts it should use parport_enable_irq(), and can also check the irq member of the parport structure representing the port.}(hji)hhhNhNubeh}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMhj(ubj<)}(hXThe parallel port (lowlevel) driver is the one that has called request_irq() and whose interrupt handler is called first. This handler does whatever needs to be done to the hardware to acknowledge the interrupt (for PC-style ports there is nothing special to be done). It then tells the IEEE 1284 code about the interrupt, which may involve reacting to an IEEE 1284 event depending on the current IEEE 1284 phase. After this, it calls **irq_func**. Needless to say, **irq_func** will be called from interrupt context, and may not block.h](hXThe parallel port (lowlevel) driver is the one that has called request_irq() and whose interrupt handler is called first. This handler does whatever needs to be done to the hardware to acknowledge the interrupt (for PC-style ports there is nothing special to be done). It then tells the IEEE 1284 code about the interrupt, which may involve reacting to an IEEE 1284 event depending on the current IEEE 1284 phase. After this, it calls }(hj)hhhNhNubj})}(h **irq_func**h]hirq_func}(hj)hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj)ubh. Needless to say, }(hj)hhhNhNubj})}(h **irq_func**h]hirq_func}(hj)hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj)ubh: will be called from interrupt context, and may not block.}(hj)hhhNhNubeh}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMhj(ubj<)}(hThe ``PARPORT_DEV_EXCL`` flag is for preventing port sharing, and so should only be used when sharing the port with other device drivers is impossible and would lead to incorrect behaviour. Use it sparingly! Normally, **flags** will be zero.h](hThe }(hj)hhhNhNubjB)}(h``PARPORT_DEV_EXCL``h]hPARPORT_DEV_EXCL}(hj)hhhNhNubah}(h]h ]h"]h$]h&]uh1jAhj)ubh flag is for preventing port sharing, and so should only be used when sharing the port with other device drivers is impossible and would lead to incorrect behaviour. Use it sparingly! Normally, }(hj)hhhNhNubj})}(h **flags**h]hflags}(hj)hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj)ubh will be zero.}(hj)hhhNhNubeh}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMhj(ubj<)}(hThis function returns a pointer to a structure that represents the device on the port, or ``NULL`` if there is not enough memory to allocate space for that structure.h](hZThis function returns a pointer to a structure that represents the device on the port, or }(hj)hhhNhNubjB)}(h``NULL``h]hNULL}(hj)hhhNhNubah}(h]h ]h"]h$]h&]uh1jAhj)ubhD if there is not enough memory to allocate space for that structure.}(hj)hhhNhNubeh}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMhj(ubeh}(h]h ]h"]h$]h&]uh1jWhj(hMghj'ubeh}(h]h ] kernelindentah"]h$]h&]uh1jrhhhhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](h،&parport_unregister_device (C function)c.parport_unregister_devicehNtauh1hhhhhhNhNubh)}(hhh](h)}(h6void parport_unregister_device (struct pardevice *dev)h]h)}(h5void parport_unregister_device(struct pardevice *dev)h](j)}(hvoidh]hvoid}(hj7*hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj3*hhh`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chM-ubj)}(h h]h }(hjF*hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj3*hhhjE*hM-ubh)}(hparport_unregister_deviceh]h)}(hparport_unregister_deviceh]hparport_unregister_device}(hjX*hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjT*ubah}(h]h ](jjeh"]h$]h&]j j uh1hhj3*hhhjE*hM-ubj)}(h(struct pardevice *dev)h]j)}(hstruct pardevice *devh](j)}(hjh]hstruct}(hjt*hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjp*ubj)}(h h]h }(hj*hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjp*ubh)}(hhh]h)}(h pardeviceh]h pardevice}(hj*hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj*ubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetj*modnameN classnameNjj )}j]j)}jjZ*sbc.parport_unregister_deviceasbuh1hhjp*ubj)}(h h]h }(hj*hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjp*ubj%)}(hj(h]h*}(hj*hhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hjp*ubh)}(hdevh]hdev}(hj*hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjp*ubeh}(h]h ]h"]h$]h&]noemphj j uh1jhjl*ubah}(h]h ]h"]h$]h&]j j uh1jhj3*hhhjE*hM-ubeh}(h]h ]h"]h$]h&]j j juh1hjjhj/*hhhjE*hM-ubah}(h]j**ah ](jjeh"]h$]h&]jj )j!huh1hhjE*hM-hj,*hhubj#)}(hhh]j<)}(h&deregister a device on a parallel porth]h&deregister a device on a parallel port}(hj*hhhNhNubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chM-hj*hhubah}(h]h ]h"]h$]h&]uh1j"hj,*hhhjE*hM-ubeh}(h]h ](j0functioneh"]h$]h&]j5j0j6j+j7j+j8j9j:uh1hhhhhhNhNubjs)}(h**Parameters** ``struct pardevice *dev`` pointer to structure representing device **Description** This undoes the effect of parport_register_device().h](j<)}(h**Parameters**h]j})}(hj+h]h Parameters}(hj+hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj+ubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chM1hj+ubj)}(hhh]j)}(hC``struct pardevice *dev`` pointer to structure representing device h](j)}(h``struct pardevice *dev``h]jB)}(hj8+h]hstruct pardevice *dev}(hj:+hhhNhNubah}(h]h ]h"]h$]h&]uh1jAhj6+ubah}(h]h ]h"]h$]h&]uh1jh`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chM.hj2+ubj)}(hhh]j<)}(h(pointer to structure representing deviceh]h(pointer to structure representing device}(hjQ+hhhNhNubah}(h]h ]h"]h$]h&]uh1j;hjM+hM.hjN+ubah}(h]h ]h"]h$]h&]uh1jhj2+ubeh}(h]h ]h"]h$]h&]uh1jhjM+hM.hj/+ubah}(h]h ]h"]h$]h&]uh1jhj+ubj<)}(h**Description**h]j})}(hjs+h]h Description}(hju+hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjq+ubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chM0hj+ubjX)}(h4This undoes the effect of parport_register_device().h]j<)}(hj+h]h4This undoes the effect of parport_register_device().}(hj+hhhNhNubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chM/hj+ubah}(h]h ]h"]h$]h&]uh1jWhj+hM/hj+ubeh}(h]h ] kernelindentah"]h$]h&]uh1jrhhhhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](h، parport_find_number (C function)c.parport_find_numberhNtauh1hhhhhhNhNubh)}(hhh](h)}(h1struct parport * parport_find_number (int number)h]h)}(h/struct parport *parport_find_number(int number)h](j)}(hjh]hstruct}(hj+hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj+hhh`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMsubj)}(h h]h }(hj+hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj+hhhj+hMsubh)}(hhh]h)}(hparporth]hparport}(hj+hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj+ubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetj+modnameN classnameNjj )}j]j)}jparport_find_numbersbc.parport_find_numberasbuh1hhj+hhhj+hMsubj)}(h h]h }(hj,hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj+hhhj+hMsubj%)}(hj(h]h*}(hj,hhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hj+hhhj+hMsubh)}(hparport_find_numberh]h)}(hj+h]hparport_find_number}(hj ,hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj,ubah}(h]h ](jjeh"]h$]h&]j j uh1hhj+hhhj+hMsubj)}(h (int number)h]j)}(h int numberh](j)}(hinth]hint}(hj;,hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj7,ubj)}(h h]h }(hjI,hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj7,ubh)}(hnumberh]hnumber}(hjW,hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj7,ubeh}(h]h ]h"]h$]h&]noemphj j uh1jhj3,ubah}(h]h ]h"]h$]h&]j j uh1jhj+hhhj+hMsubeh}(h]h ]h"]h$]h&]j j juh1hjjhj+hhhj+hMsubah}(h]j+ah ](jjeh"]h$]h&]jj )j!huh1hhj+hMshj+hhubj#)}(hhh]j<)}(hfind a parallel port by numberh]hfind a parallel port by number}(hj,hhhNhNubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMshj~,hhubah}(h]h ]h"]h$]h&]uh1j"hj+hhhj+hMsubeh}(h]h ](j0functioneh"]h$]h&]j5j0j6j,j7j,j8j9j:uh1hhhhhhNhNubjs)}(hXU**Parameters** ``int number`` parallel port number **Description** This returns the parallel port with the specified number, or ``NULL`` if there is none. There is an implicit parport_get_port() done already; to throw away the reference to the port that parport_find_number() gives you, use parport_put_port().h](j<)}(h**Parameters**h]j})}(hj,h]h Parameters}(hj,hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj,ubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMwhj,ubj)}(hhh]j)}(h$``int number`` parallel port number h](j)}(h``int number``h]jB)}(hj,h]h int number}(hj,hhhNhNubah}(h]h ]h"]h$]h&]uh1jAhj,ubah}(h]h ]h"]h$]h&]uh1jh`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMthj,ubj)}(hhh]j<)}(hparallel port numberh]hparallel port number}(hj,hhhNhNubah}(h]h ]h"]h$]h&]uh1j;hj,hMthj,ubah}(h]h ]h"]h$]h&]uh1jhj,ubeh}(h]h ]h"]h$]h&]uh1jhj,hMthj,ubah}(h]h ]h"]h$]h&]uh1jhj,ubj<)}(h**Description**h]j})}(hj,h]h Description}(hj,hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj,ubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMvhj,ubjX)}(hThis returns the parallel port with the specified number, or ``NULL`` if there is none. There is an implicit parport_get_port() done already; to throw away the reference to the port that parport_find_number() gives you, use parport_put_port().h](j<)}(hWThis returns the parallel port with the specified number, or ``NULL`` if there is none.h](h=This returns the parallel port with the specified number, or }(hj-hhhNhNubjB)}(h``NULL``h]hNULL}(hj-hhhNhNubah}(h]h ]h"]h$]h&]uh1jAhj-ubh if there is none.}(hj-hhhNhNubeh}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMuhj-ubj<)}(hThere is an implicit parport_get_port() done already; to throw away the reference to the port that parport_find_number() gives you, use parport_put_port().h]hThere is an implicit parport_get_port() done already; to throw away the reference to the port that parport_find_number() gives you, use parport_put_port().}(hj8-hhhNhNubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMxhj-ubeh}(h]h ]h"]h$]h&]uh1jWhj7-hMuhj,ubeh}(h]h ] kernelindentah"]h$]h&]uh1jrhhhhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](h،parport_find_base (C function)c.parport_find_basehNtauh1hhhhhhNhNubh)}(hhh](h)}(h7struct parport * parport_find_base (unsigned long base)h]h)}(h5struct parport *parport_find_base(unsigned long base)h](j)}(hjh]hstruct}(hjm-hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhji-hhh`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMubj)}(h h]h }(hj{-hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhji-hhhjz-hMubh)}(hhh]h)}(hparporth]hparport}(hj-hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj-ubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetj-modnameN classnameNjj )}j]j)}jparport_find_basesbc.parport_find_baseasbuh1hhji-hhhjz-hMubj)}(h h]h }(hj-hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhji-hhhjz-hMubj%)}(hj(h]h*}(hj-hhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hji-hhhjz-hMubh)}(hparport_find_baseh]h)}(hj-h]hparport_find_base}(hj-hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj-ubah}(h]h ](jjeh"]h$]h&]j j uh1hhji-hhhjz-hMubj)}(h(unsigned long base)h]j)}(hunsigned long baseh](j)}(hunsignedh]hunsigned}(hj-hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj-ubj)}(h h]h }(hj-hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj-ubj)}(hlongh]hlong}(hj.hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj-ubj)}(h h]h }(hj.hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj-ubh)}(hbaseh]hbase}(hj.hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj-ubeh}(h]h ]h"]h$]h&]noemphj j uh1jhj-ubah}(h]h ]h"]h$]h&]j j uh1jhji-hhhjz-hMubeh}(h]h ]h"]h$]h&]j j juh1hjjhje-hhhjz-hMubah}(h]j`-ah ](jjeh"]h$]h&]jj )j!huh1hhjz-hMhjb-hhubj#)}(hhh]j<)}(h$find a parallel port by base addressh]h$find a parallel port by base address}(hjI.hhhNhNubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMhjF.hhubah}(h]h ]h"]h$]h&]uh1j"hjb-hhhjz-hMubeh}(h]h ](j0functioneh"]h$]h&]j5j0j6ja.j7ja.j8j9j:uh1hhhhhhNhNubjs)}(hX]**Parameters** ``unsigned long base`` base I/O address **Description** This returns the parallel port with the specified base address, or ``NULL`` if there is none. There is an implicit parport_get_port() done already; to throw away the reference to the port that parport_find_base() gives you, use parport_put_port().h](j<)}(h**Parameters**h]j})}(hjk.h]h Parameters}(hjm.hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hji.ubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMhje.ubj)}(hhh]j)}(h(``unsigned long base`` base I/O address h](j)}(h``unsigned long base``h]jB)}(hj.h]hunsigned long base}(hj.hhhNhNubah}(h]h ]h"]h$]h&]uh1jAhj.ubah}(h]h ]h"]h$]h&]uh1jh`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMhj.ubj)}(hhh]j<)}(hbase I/O addressh]hbase I/O address}(hj.hhhNhNubah}(h]h ]h"]h$]h&]uh1j;hj.hMhj.ubah}(h]h ]h"]h$]h&]uh1jhj.ubeh}(h]h ]h"]h$]h&]uh1jhj.hMhj.ubah}(h]h ]h"]h$]h&]uh1jhje.ubj<)}(h**Description**h]j})}(hj.h]h Description}(hj.hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj.ubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMhje.ubjX)}(hThis returns the parallel port with the specified base address, or ``NULL`` if there is none. There is an implicit parport_get_port() done already; to throw away the reference to the port that parport_find_base() gives you, use parport_put_port().h](j<)}(h]This returns the parallel port with the specified base address, or ``NULL`` if there is none.h](hCThis returns the parallel port with the specified base address, or }(hj.hhhNhNubjB)}(h``NULL``h]hNULL}(hj.hhhNhNubah}(h]h ]h"]h$]h&]uh1jAhj.ubh if there is none.}(hj.hhhNhNubeh}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMhj.ubj<)}(hThere is an implicit parport_get_port() done already; to throw away the reference to the port that parport_find_base() gives you, use parport_put_port().h]hThere is an implicit parport_get_port() done already; to throw away the reference to the port that parport_find_base() gives you, use parport_put_port().}(hj/hhhNhNubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMhj.ubeh}(h]h ]h"]h$]h&]uh1jWhj.hMhje.ubeh}(h]h ] kernelindentah"]h$]h&]uh1jrhhhhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](h،parport_claim (C function)c.parport_claimhNtauh1hhhhhhNhNubh)}(hhh](h)}(h)int parport_claim (struct pardevice *dev)h]h)}(h(int parport_claim(struct pardevice *dev)h](j)}(hinth]hint}(hj5/hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj1/hhh`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMubj)}(h h]h }(hjD/hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj1/hhhjC/hMubh)}(h parport_claimh]h)}(h parport_claimh]h parport_claim}(hjV/hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjR/ubah}(h]h ](jjeh"]h$]h&]j j uh1hhj1/hhhjC/hMubj)}(h(struct pardevice *dev)h]j)}(hstruct pardevice *devh](j)}(hjh]hstruct}(hjr/hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjn/ubj)}(h h]h }(hj/hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjn/ubh)}(hhh]h)}(h pardeviceh]h pardevice}(hj/hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj/ubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetj/modnameN classnameNjj )}j]j)}jjX/sbc.parport_claimasbuh1hhjn/ubj)}(h h]h }(hj/hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjn/ubj%)}(hj(h]h*}(hj/hhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hjn/ubh)}(hdevh]hdev}(hj/hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjn/ubeh}(h]h ]h"]h$]h&]noemphj j uh1jhjj/ubah}(h]h ]h"]h$]h&]j j uh1jhj1/hhhjC/hMubeh}(h]h ]h"]h$]h&]j j juh1hjjhj-/hhhjC/hMubah}(h]j(/ah ](jjeh"]h$]h&]jj )j!huh1hhjC/hMhj*/hhubj#)}(hhh]j<)}(h&claim access to a parallel port deviceh]h&claim access to a parallel port device}(hj/hhhNhNubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMhj/hhubah}(h]h ]h"]h$]h&]uh1j"hj*/hhhjC/hMubeh}(h]h ](j0functioneh"]h$]h&]j5j0j6j 0j7j 0j8j9j:uh1hhhhhhNhNubjs)}(hX**Parameters** ``struct pardevice *dev`` pointer to structure representing a device on the port **Description** This function will not block and so can be used from interrupt context. If parport_claim() succeeds in claiming access to the port it returns zero and the port is available to use. It may fail (returning non-zero) if the port is in use by another driver and that driver is not willing to relinquish control of the port.h](j<)}(h**Parameters**h]j})}(hj0h]h Parameters}(hj0hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj0ubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMhj0ubj)}(hhh]j)}(hQ``struct pardevice *dev`` pointer to structure representing a device on the port h](j)}(h``struct pardevice *dev``h]jB)}(hj60h]hstruct pardevice *dev}(hj80hhhNhNubah}(h]h ]h"]h$]h&]uh1jAhj40ubah}(h]h ]h"]h$]h&]uh1jh`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMhj00ubj)}(hhh]j<)}(h6pointer to structure representing a device on the porth]h6pointer to structure representing a device on the port}(hjO0hhhNhNubah}(h]h ]h"]h$]h&]uh1j;hjK0hMhjL0ubah}(h]h ]h"]h$]h&]uh1jhj00ubeh}(h]h ]h"]h$]h&]uh1jhjK0hMhj-0ubah}(h]h ]h"]h$]h&]uh1jhj0ubj<)}(h**Description**h]j})}(hjq0h]h Description}(hjs0hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjo0ubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMhj0ubjX)}(hXAThis function will not block and so can be used from interrupt context. If parport_claim() succeeds in claiming access to the port it returns zero and the port is available to use. It may fail (returning non-zero) if the port is in use by another driver and that driver is not willing to relinquish control of the port.h]j<)}(hXAThis function will not block and so can be used from interrupt context. If parport_claim() succeeds in claiming access to the port it returns zero and the port is available to use. It may fail (returning non-zero) if the port is in use by another driver and that driver is not willing to relinquish control of the port.h]hXAThis function will not block and so can be used from interrupt context. If parport_claim() succeeds in claiming access to the port it returns zero and the port is available to use. It may fail (returning non-zero) if the port is in use by another driver and that driver is not willing to relinquish control of the port.}(hj0hhhNhNubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMhj0ubah}(h]h ]h"]h$]h&]uh1jWhj0hMhj0ubeh}(h]h ] kernelindentah"]h$]h&]uh1jrhhhhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](h،#parport_claim_or_block (C function)c.parport_claim_or_blockhNtauh1hhhhhhNhNubh)}(hhh](h)}(h2int parport_claim_or_block (struct pardevice *dev)h]h)}(h1int parport_claim_or_block(struct pardevice *dev)h](j)}(hinth]hint}(hj0hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj0hhh`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chM%ubj)}(h h]h }(hj0hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj0hhhj0hM%ubh)}(hparport_claim_or_blockh]h)}(hparport_claim_or_blockh]hparport_claim_or_block}(hj0hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj0ubah}(h]h ](jjeh"]h$]h&]j j uh1hhj0hhhj0hM%ubj)}(h(struct pardevice *dev)h]j)}(hstruct pardevice *devh](j)}(hjh]hstruct}(hj0hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj0ubj)}(h h]h }(hj 1hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj0ubh)}(hhh]h)}(h pardeviceh]h pardevice}(hj1hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj1ubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetj1modnameN classnameNjj )}j]j)}jj0sbc.parport_claim_or_blockasbuh1hhj0ubj)}(h h]h }(hj;1hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj0ubj%)}(hj(h]h*}(hjI1hhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hj0ubh)}(hdevh]hdev}(hjV1hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj0ubeh}(h]h ]h"]h$]h&]noemphj j uh1jhj0ubah}(h]h ]h"]h$]h&]j j uh1jhj0hhhj0hM%ubeh}(h]h ]h"]h$]h&]j j juh1hjjhj0hhhj0hM%ubah}(h]j0ah ](jjeh"]h$]h&]jj )j!huh1hhj0hM%hj0hhubj#)}(hhh]j<)}(h&claim access to a parallel port deviceh]h&claim access to a parallel port device}(hj1hhhNhNubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chM%hj}1hhubah}(h]h ]h"]h$]h&]uh1j"hj0hhhj0hM%ubeh}(h]h ](j0functioneh"]h$]h&]j5j0j6j1j7j1j8j9j:uh1hhhhhhNhNubjs)}(hXt**Parameters** ``struct pardevice *dev`` pointer to structure representing a device on the port **Description** This behaves like parport_claim(), but will block if necessary to wait for the port to be free. A return value of 1 indicates that it slept; 0 means that it succeeded without needing to sleep. A negative error code indicates failure.h](j<)}(h**Parameters**h]j})}(hj1h]h Parameters}(hj1hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj1ubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chM)hj1ubj)}(hhh]j)}(hQ``struct pardevice *dev`` pointer to structure representing a device on the port h](j)}(h``struct pardevice *dev``h]jB)}(hj1h]hstruct pardevice *dev}(hj1hhhNhNubah}(h]h ]h"]h$]h&]uh1jAhj1ubah}(h]h ]h"]h$]h&]uh1jh`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chM&hj1ubj)}(hhh]j<)}(h6pointer to structure representing a device on the porth]h6pointer to structure representing a device on the port}(hj1hhhNhNubah}(h]h ]h"]h$]h&]uh1j;hj1hM&hj1ubah}(h]h ]h"]h$]h&]uh1jhj1ubeh}(h]h ]h"]h$]h&]uh1jhj1hM&hj1ubah}(h]h ]h"]h$]h&]uh1jhj1ubj<)}(h**Description**h]j})}(hj1h]h Description}(hj1hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj1ubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chM(hj1ubjX)}(hThis behaves like parport_claim(), but will block if necessary to wait for the port to be free. A return value of 1 indicates that it slept; 0 means that it succeeded without needing to sleep. A negative error code indicates failure.h]j<)}(hThis behaves like parport_claim(), but will block if necessary to wait for the port to be free. A return value of 1 indicates that it slept; 0 means that it succeeded without needing to sleep. A negative error code indicates failure.h]hThis behaves like parport_claim(), but will block if necessary to wait for the port to be free. A return value of 1 indicates that it slept; 0 means that it succeeded without needing to sleep. A negative error code indicates failure.}(hj2hhhNhNubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chM'hj2ubah}(h]h ]h"]h$]h&]uh1jWhj$2hM'hj1ubeh}(h]h ] kernelindentah"]h$]h&]uh1jrhhhhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](h،parport_release (C function)c.parport_releasehNtauh1hhhhhhNhNubh)}(hhh](h)}(h,void parport_release (struct pardevice *dev)h]h)}(h+void parport_release(struct pardevice *dev)h](j)}(hvoidh]hvoid}(hjK2hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjG2hhh`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMgubj)}(h h]h }(hjZ2hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjG2hhhjY2hMgubh)}(hparport_releaseh]h)}(hparport_releaseh]hparport_release}(hjl2hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjh2ubah}(h]h ](jjeh"]h$]h&]j j uh1hhjG2hhhjY2hMgubj)}(h(struct pardevice *dev)h]j)}(hstruct pardevice *devh](j)}(hjh]hstruct}(hj2hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj2ubj)}(h h]h }(hj2hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj2ubh)}(hhh]h)}(h pardeviceh]h pardevice}(hj2hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj2ubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetj2modnameN classnameNjj )}j]j)}jjn2sbc.parport_releaseasbuh1hhj2ubj)}(h h]h }(hj2hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj2ubj%)}(hj(h]h*}(hj2hhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hj2ubh)}(hdevh]hdev}(hj2hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj2ubeh}(h]h ]h"]h$]h&]noemphj j uh1jhj2ubah}(h]h ]h"]h$]h&]j j uh1jhjG2hhhjY2hMgubeh}(h]h ]h"]h$]h&]j j juh1hjjhjC2hhhjY2hMgubah}(h]j>2ah ](jjeh"]h$]h&]jj )j!huh1hhjY2hMghj@2hhubj#)}(hhh]j<)}(h(give up access to a parallel port deviceh]h(give up access to a parallel port device}(hj 3hhhNhNubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMghj3hhubah}(h]h ]h"]h$]h&]uh1j"hj@2hhhjY2hMgubeh}(h]h ](j0functioneh"]h$]h&]j5j0j6j#3j7j#3j8j9j:uh1hhhhhhNhNubjs)}(hX%**Parameters** ``struct pardevice *dev`` pointer to structure representing parallel port device **Description** This function cannot fail, but it should not be called without the port claimed. Similarly, if the port is already claimed you should not try claiming it again.h](j<)}(h**Parameters**h]j})}(hj-3h]h Parameters}(hj/3hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj+3ubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMkhj'3ubj)}(hhh]j)}(hQ``struct pardevice *dev`` pointer to structure representing parallel port device h](j)}(h``struct pardevice *dev``h]jB)}(hjL3h]hstruct pardevice *dev}(hjN3hhhNhNubah}(h]h ]h"]h$]h&]uh1jAhjJ3ubah}(h]h ]h"]h$]h&]uh1jh`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMhhjF3ubj)}(hhh]j<)}(h6pointer to structure representing parallel port deviceh]h6pointer to structure representing parallel port device}(hje3hhhNhNubah}(h]h ]h"]h$]h&]uh1j;hja3hMhhjb3ubah}(h]h ]h"]h$]h&]uh1jhjF3ubeh}(h]h ]h"]h$]h&]uh1jhja3hMhhjC3ubah}(h]h ]h"]h$]h&]uh1jhj'3ubj<)}(h**Description**h]j})}(hj3h]h Description}(hj3hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj3ubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMjhj'3ubjX)}(hThis function cannot fail, but it should not be called without the port claimed. Similarly, if the port is already claimed you should not try claiming it again.h]j<)}(hThis function cannot fail, but it should not be called without the port claimed. Similarly, if the port is already claimed you should not try claiming it again.h]hThis function cannot fail, but it should not be called without the port claimed. Similarly, if the port is already claimed you should not try claiming it again.}(hj3hhhNhNubah}(h]h ]h"]h$]h&]uh1j;h`/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:10: ./drivers/parport/share.chMihj3ubah}(h]h ]h"]h$]h&]uh1jWhj3hMihj'3ubeh}(h]h ] kernelindentah"]h$]h&]uh1jrhhhhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](h،parport_open (C function)c.parport_openhNtauh1hhhhhhNhNubh)}(hhh](h)}(h>struct pardevice * parport_open (int devnum, const char *name)h]h)}(hhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj=ubh)}(hlineh]hline}(hj>hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj=ubeh}(h]h ]h"]h$]h&]noemphj j uh1jhj=ubah}(h]h ]h"]h$]h&]j j uh1jhj=hhhj=hM\ubeh}(h]h ]h"]h$]h&]j j juh1hjjhj=hhhj=hM\ubah}(h]j=ah ](jjeh"]h$]h&]jj )j!huh1hhj=hM\hj=hhubj#)}(hhh]j<)}(h%remove a 16x50 serial port at runtimeh]h%remove a 16x50 serial port at runtime}(hjD>hhhNhNubah}(h]h ]h"]h$]h&]uh1j;hl/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:19: ./drivers/tty/serial/8250/8250_core.chM\hjA>hhubah}(h]h ]h"]h$]h&]uh1j"hj=hhhj=hM\ubeh}(h]h ](j0functioneh"]h$]h&]j5j0j6j\>j7j\>j8j9j:uh1hhhhj7hNhNubjs)}(h**Parameters** ``int line`` serial line number **Description** Remove one serial port. This may not be called from interrupt context. We hand the port back to the our control.h](j<)}(h**Parameters**h]j})}(hjf>h]h Parameters}(hjh>hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjd>ubah}(h]h ]h"]h$]h&]uh1j;hl/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:19: ./drivers/tty/serial/8250/8250_core.chM`hj`>ubj)}(hhh]j)}(h ``int line`` serial line number h](j)}(h ``int line``h]jB)}(hj>h]hint line}(hj>hhhNhNubah}(h]h ]h"]h$]h&]uh1jAhj>ubah}(h]h ]h"]h$]h&]uh1jhl/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:19: ./drivers/tty/serial/8250/8250_core.chM]hj>ubj)}(hhh]j<)}(hserial line numberh]hserial line number}(hj>hhhNhNubah}(h]h ]h"]h$]h&]uh1j;hj>hM]hj>ubah}(h]h ]h"]h$]h&]uh1jhj>ubeh}(h]h ]h"]h$]h&]uh1jhj>hM]hj|>ubah}(h]h ]h"]h$]h&]uh1jhj`>ubj<)}(h**Description**h]j})}(hj>h]h Description}(hj>hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj>ubah}(h]h ]h"]h$]h&]uh1j;hl/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:19: ./drivers/tty/serial/8250/8250_core.chM_hj`>ubjX)}(hrRemove one serial port. This may not be called from interrupt context. We hand the port back to the our control.h]j<)}(hrRemove one serial port. This may not be called from interrupt context. We hand the port back to the our control.h]hrRemove one serial port. This may not be called from interrupt context. We hand the port back to the our control.}(hj>hhhNhNubah}(h]h ]h"]h$]h&]uh1j;hl/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:19: ./drivers/tty/serial/8250/8250_core.chM^hj>ubah}(h]h ]h"]h$]h&]uh1jWhj>hM^hj`>ubeh}(h]h ] kernelindentah"]h$]h&]uh1jrhj7hhhNhNubj<)}(h'See serial/driver.rst for related APIs.h]h'See serial/driver.rst for related APIs.}(hj>hhhNhNubah}(h]h ]h"]h$]h&]uh1j;hhhKhj7hhubeh}(h]x50-uart-driverah ]h"]16x50 uart driverah$]h&]uh1hhhhhhhhKubh)}(hhh](h)}(hPulse-Width Modulation (PWM)h]hPulse-Width Modulation (PWM)}(hj?hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj ?hhhhhKubj<)}(hpPulse-width modulation is a modulation technique primarily used to control power supplied to electrical devices.h]hpPulse-width modulation is a modulation technique primarily used to control power supplied to electrical devices.}(hj?hhhNhNubah}(h]h ]h"]h$]h&]uh1j;hhhKhj ?hhubj<)}(hXNThe PWM framework provides an abstraction for providers and consumers of PWM signals. A controller that provides one or more PWM signals is registered as :c:type:`struct pwm_chip `. Providers are expected to embed this structure in a driver-specific structure. This structure contains fields that describe a particular chip.h](hThe PWM framework provides an abstraction for providers and consumers of PWM signals. A controller that provides one or more PWM signals is registered as }(hj+?hhhNhNubh)}(h$:c:type:`struct pwm_chip `h]jB)}(hj5?h]hstruct pwm_chip}(hj7?hhhNhNubah}(h]h ](xrefj0c-typeeh"]h$]h&]uh1jAhj3?ubah}(h]h ]h"]h$]h&]refdocdriver-api/miscellaneous refdomainj0reftypetype refexplicitrefwarnjj )}j]sb reftargetpwm_chipuh1hhhhKhj+?ubh. Providers are expected to embed this structure in a driver-specific structure. This structure contains fields that describe a particular chip.}(hj+?hhhNhNubeh}(h]h ]h"]h$]h&]uh1j;hhhKhj ?hhubj<)}(hA chip exposes one or more PWM signal sources, each of which exposed as a :c:type:`struct pwm_device `. Operations can be performed on PWM devices to control the period, duty cycle, polarity and active state of the signal.h](hJA chip exposes one or more PWM signal sources, each of which exposed as a }(hjb?hhhNhNubh)}(h(:c:type:`struct pwm_device `h]jB)}(hjl?h]hstruct pwm_device}(hjn?hhhNhNubah}(h]h ](jA?j0c-typeeh"]h$]h&]uh1jAhjj?ubah}(h]h ]h"]h$]h&]refdocjM? refdomainj0reftypetype refexplicitrefwarnjjS?jV? pwm_deviceuh1hhhhK$hjb?ubhx. Operations can be performed on PWM devices to control the period, duty cycle, polarity and active state of the signal.}(hjb?hhhNhNubeh}(h]h ]h"]h$]h&]uh1j;hhhK$hj ?hhubj<)}(hfNote that PWM devices are exclusive resources: they can always only be used by one consumer at a time.h]hfNote that PWM devices are exclusive resources: they can always only be used by one consumer at a time.}(hj?hhhNhNubah}(h]h ]h"]h$]h&]uh1j;hhhK)hj ?hhubh)}(hhh]h}(h]h ]h"]h$]h&]entries](h،pwm_polarity (C enum)c.pwm_polarityhNtauh1hhj ?hhhNhNubh)}(hhh](h)}(h pwm_polarityh]h)}(henum pwm_polarityh](j)}(henumh]henum}(hj?hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj?hhh\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhKubj)}(h h]h }(hj?hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj?hhhj?hKubh)}(h pwm_polarityh]h)}(hj?h]h pwm_polarity}(hj?hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj?ubah}(h]h ](jjeh"]h$]h&]j j uh1hhj?hhhj?hKubeh}(h]h ]h"]h$]h&]j j juh1hjjhj?hhhj?hKubah}(h]j?ah ](jjeh"]h$]h&]jj )j!huh1hhj?hKhj?hhubj#)}(hhh]j<)}(hpolarity of a PWM signalh]hpolarity of a PWM signal}(hj?hhhNhNubah}(h]h ]h"]h$]h&]uh1j;h\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhKhj?hhubah}(h]h ]h"]h$]h&]uh1j"hj?hhhj?hKubeh}(h]h ](j0enumeh"]h$]h&]j5j0j6j@j7j@j8j9j:uh1hhhhj ?hNhNubjs)}(hX1**Constants** ``PWM_POLARITY_NORMAL`` a high signal for the duration of the duty- cycle, followed by a low signal for the remainder of the pulse period ``PWM_POLARITY_INVERSED`` a low signal for the duration of the duty- cycle, followed by a high signal for the remainder of the pulse periodh](j<)}(h **Constants**h]j})}(hj@h]h Constants}(hj!@hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj@ubah}(h]h ]h"]h$]h&]uh1j;h\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhKhj@ubj)}(hhh](j)}(h``PWM_POLARITY_NORMAL`` a high signal for the duration of the duty- cycle, followed by a low signal for the remainder of the pulse period h](j)}(h``PWM_POLARITY_NORMAL``h]jB)}(hj>@h]hPWM_POLARITY_NORMAL}(hj@@hhhNhNubah}(h]h ]h"]h$]h&]uh1jAhj<@ubah}(h]h ]h"]h$]h&]uh1jh\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhKhj8@ubj)}(hhh]j<)}(hqa high signal for the duration of the duty- cycle, followed by a low signal for the remainder of the pulse periodh]hqa high signal for the duration of the duty- cycle, followed by a low signal for the remainder of the pulse period}(hjW@hhhNhNubah}(h]h ]h"]h$]h&]uh1j;h\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhKhjT@ubah}(h]h ]h"]h$]h&]uh1jhj8@ubeh}(h]h ]h"]h$]h&]uh1jhjS@hKhj5@ubj)}(h``PWM_POLARITY_INVERSED`` a low signal for the duration of the duty- cycle, followed by a high signal for the remainder of the pulse periodh](j)}(h``PWM_POLARITY_INVERSED``h]jB)}(hjx@h]hPWM_POLARITY_INVERSED}(hjz@hhhNhNubah}(h]h ]h"]h$]h&]uh1jAhjv@ubah}(h]h ]h"]h$]h&]uh1jh\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhKhjr@ubj)}(hhh]j<)}(hqa low signal for the duration of the duty- cycle, followed by a high signal for the remainder of the pulse periodh]hqa low signal for the duration of the duty- cycle, followed by a high signal for the remainder of the pulse period}(hj@hhhNhNubah}(h]h ]h"]h$]h&]uh1j;h\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhKhj@ubah}(h]h ]h"]h$]h&]uh1jhjr@ubeh}(h]h ]h"]h$]h&]uh1jhj@hKhj5@ubeh}(h]h ]h"]h$]h&]uh1jhj@ubeh}(h]h ] kernelindentah"]h$]h&]uh1jrhj ?hhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](h،pwm_args (C struct) c.pwm_argshNtauh1hhj ?hhhNhNubh)}(hhh](h)}(hpwm_argsh]h)}(hstruct pwm_argsh](j)}(hjh]hstruct}(hj@hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj@hhh\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhK%ubj)}(h h]h }(hj@hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj@hhhj@hK%ubh)}(hpwm_argsh]h)}(hj@h]hpwm_args}(hj@hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj@ubah}(h]h ](jjeh"]h$]h&]j j uh1hhj@hhhj@hK%ubeh}(h]h ]h"]h$]h&]j j juh1hjjhj@hhhj@hK%ubah}(h]j@ah ](jjeh"]h$]h&]jj )j!huh1hhj@hK%hj@hhubj#)}(hhh]j<)}(hboard-dependent PWM argumentsh]hboard-dependent PWM arguments}(hjAhhhNhNubah}(h]h ]h"]h$]h&]uh1j;h\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhK hjAhhubah}(h]h ]h"]h$]h&]uh1j"hj@hhhj@hK%ubeh}(h]h ](j0structeh"]h$]h&]j5j0j6j,Aj7j,Aj8j9j:uh1hhhhj ?hNhNubjs)}(hX **Definition**:: struct pwm_args { u64 period; enum pwm_polarity polarity; }; **Members** ``period`` reference period ``polarity`` reference polarity **Description** This structure describes board-dependent arguments attached to a PWM device. These arguments are usually retrieved from the PWM lookup table or device tree. Do not confuse this with the PWM state: PWM arguments represent the initial configuration that users want to use on this PWM device rather than the current PWM hardware state.h](jX)}(hc**Definition**:: struct pwm_args { u64 period; enum pwm_polarity polarity; }; h](j<)}(h**Definition**::h](j})}(h**Definition**h]h Definition}(hjhjBubj<)}(hX-This is a representation of a PWM waveform alternative to struct pwm_state below. It's more expressive than struct pwm_state as it contains a duty_offset_ns and so can represent offsets other than zero (with .polarity = PWM_POLARITY_NORMAL) and period - duty_cycle (.polarity = PWM_POLARITY_INVERSED).h]hX/This is a representation of a PWM waveform alternative to struct pwm_state below. It’s more expressive than struct pwm_state as it contains a duty_offset_ns and so can represent offsets other than zero (with .polarity = PWM_POLARITY_NORMAL) and period - duty_cycle (.polarity = PWM_POLARITY_INVERSED).}(hjChhhNhNubah}(h]h ]h"]h$]h&]uh1j;h\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhK;hjBubj<)}(hX#Note there is no explicit bool for enabled. A "disabled" PWM is represented by .period_length_ns = 0. Note further that the behaviour of a "disabled" PWM is undefined. Depending on the hardware's capabilities it might drive the active or inactive level, go high-z or even continue to toggle.h]hX-Note there is no explicit bool for enabled. A “disabled” PWM is represented by .period_length_ns = 0. Note further that the behaviour of a “disabled” PWM is undefined. Depending on the hardware’s capabilities it might drive the active or inactive level, go high-z or even continue to toggle.}(hjChhhNhNubah}(h]h ]h"]h$]h&]uh1j;h\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhKAhjBubj<)}(h.The unit for all three members is nanoseconds.h]h.The unit for all three members is nanoseconds.}(hjChhhNhNubah}(h]h ]h"]h$]h&]uh1j;h\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhKFhjBubeh}(h]h ] kernelindentah"]h$]h&]uh1jrhj ?hhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](h،pwm_device (C struct) c.pwm_devicehNtauh1hhj ?hhhNhNubh)}(hhh](h)}(h pwm_deviceh]h)}(hstruct pwm_deviceh](j)}(hjh]hstruct}(hj DhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjDhhh\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhKKubj)}(h h]h }(hj.DhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjDhhhj-DhKKubh)}(h pwm_deviceh]h)}(hjDh]h pwm_device}(hj@DhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjprepare a new state to be applied with pwm_apply_might_sleep()h]h>prepare a new state to be applied with pwm_apply_might_sleep()}(hjJhhhNhNubah}(h]h ]h"]h$]h&]uh1j;h\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhKhjJhhubah}(h]h ]h"]h$]h&]uh1j"hjHhhhjHhKubeh}(h]h ](j0functioneh"]h$]h&]j5j0j6j1Jj7j1Jj8j9j:uh1hhhhj ?hNhNubjs)}(hX0**Parameters** ``const struct pwm_device *pwm`` PWM device ``struct pwm_state *state`` state to fill with the prepared PWM state **Description** This functions prepares a state that can later be tweaked and applied to the PWM device with pwm_apply_might_sleep(). This is a convenient function that first retrieves the current PWM state and the replaces the period and polarity fields with the reference values defined in pwm->args. Once the function returns, you can adjust the ->enabled and ->duty_cycle fields according to your needs before calling pwm_apply_might_sleep(). ->duty_cycle is initially set to zero to avoid cases where the current ->duty_cycle value exceed the pwm_args->period one, which would trigger an error if the user calls pwm_apply_might_sleep() without adjusting ->duty_cycle first.h](j<)}(h**Parameters**h]j})}(hj;Jh]h Parameters}(hj=JhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj9Jubah}(h]h ]h"]h$]h&]uh1j;h\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhKhj5Jubj)}(hhh](j)}(h,``const struct pwm_device *pwm`` PWM device h](j)}(h ``const struct pwm_device *pwm``h]jB)}(hjZJh]hconst struct pwm_device *pwm}(hj\JhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhjXJubah}(h]h ]h"]h$]h&]uh1jh\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhKhjTJubj)}(hhh]j<)}(h PWM deviceh]h PWM device}(hjsJhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hjoJhKhjpJubah}(h]h ]h"]h$]h&]uh1jhjTJubeh}(h]h ]h"]h$]h&]uh1jhjoJhKhjQJubj)}(hF``struct pwm_state *state`` state to fill with the prepared PWM state h](j)}(h``struct pwm_state *state``h]jB)}(hjJh]hstruct pwm_state *state}(hjJhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhjJubah}(h]h ]h"]h$]h&]uh1jh\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhKhjJubj)}(hhh]j<)}(h)state to fill with the prepared PWM stateh]h)state to fill with the prepared PWM state}(hjJhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hjJhKhjJubah}(h]h ]h"]h$]h&]uh1jhjJubeh}(h]h ]h"]h$]h&]uh1jhjJhKhjQJubeh}(h]h ]h"]h$]h&]uh1jhj5Jubj<)}(h**Description**h]j})}(hjJh]h Description}(hjJhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjJubah}(h]h ]h"]h$]h&]uh1j;h\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhKhj5Jubj<)}(hXThis functions prepares a state that can later be tweaked and applied to the PWM device with pwm_apply_might_sleep(). This is a convenient function that first retrieves the current PWM state and the replaces the period and polarity fields with the reference values defined in pwm->args. Once the function returns, you can adjust the ->enabled and ->duty_cycle fields according to your needs before calling pwm_apply_might_sleep().h]hXThis functions prepares a state that can later be tweaked and applied to the PWM device with pwm_apply_might_sleep(). This is a convenient function that first retrieves the current PWM state and the replaces the period and polarity fields with the reference values defined in pwm->args. Once the function returns, you can adjust the ->enabled and ->duty_cycle fields according to your needs before calling pwm_apply_might_sleep().}(hjJhhhNhNubah}(h]h ]h"]h$]h&]uh1j;h\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhKhj5Jubj<)}(h->duty_cycle is initially set to zero to avoid cases where the current ->duty_cycle value exceed the pwm_args->period one, which would trigger an error if the user calls pwm_apply_might_sleep() without adjusting ->duty_cycle first.h]h->duty_cycle is initially set to zero to avoid cases where the current ->duty_cycle value exceed the pwm_args->period one, which would trigger an error if the user calls pwm_apply_might_sleep() without adjusting ->duty_cycle first.}(hjJhhhNhNubah}(h]h ]h"]h$]h&]uh1j;h\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhKhj5Jubeh}(h]h ] kernelindentah"]h$]h&]uh1jrhj ?hhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](h،(pwm_get_relative_duty_cycle (C function)c.pwm_get_relative_duty_cyclehNtauh1hhj ?hhhNhNubh)}(hhh](h)}(h\unsigned int pwm_get_relative_duty_cycle (const struct pwm_state *state, unsigned int scale)h]h)}(h[unsigned int pwm_get_relative_duty_cycle(const struct pwm_state *state, unsigned int scale)h](j)}(hunsignedh]hunsigned}(hj"KhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjKhhh\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhKubj)}(h h]h }(hj1KhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjKhhhj0KhKubj)}(hinth]hint}(hj?KhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjKhhhj0KhKubj)}(h h]h }(hjMKhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjKhhhj0KhKubh)}(hpwm_get_relative_duty_cycleh]h)}(hpwm_get_relative_duty_cycleh]hpwm_get_relative_duty_cycle}(hj_KhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj[Kubah}(h]h ](jjeh"]h$]h&]j j uh1hhjKhhhj0KhKubj)}(h3(const struct pwm_state *state, unsigned int scale)h](j)}(hconst struct pwm_state *stateh](j)}(hjh]hconst}(hj{KhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjwKubj)}(h h]h }(hjKhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjwKubj)}(hjh]hstruct}(hjKhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjwKubj)}(h h]h }(hjKhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjwKubh)}(hhh]h)}(h pwm_stateh]h pwm_state}(hjKhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjKubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetjKmodnameN classnameNjj )}j]j)}jjaKsbc.pwm_get_relative_duty_cycleasbuh1hhjwKubj)}(h h]h }(hjKhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjwKubj%)}(hj(h]h*}(hjKhhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hjwKubh)}(hstateh]hstate}(hjKhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjwKubeh}(h]h ]h"]h$]h&]noemphj j uh1jhjsKubj)}(hunsigned int scaleh](j)}(hunsignedh]hunsigned}(hjLhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjLubj)}(h h]h }(hjLhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjLubj)}(hinth]hint}(hj$LhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjLubj)}(h h]h }(hj2LhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjLubh)}(hscaleh]hscale}(hj@LhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjLubeh}(h]h ]h"]h$]h&]noemphj j uh1jhjsKubeh}(h]h ]h"]h$]h&]j j uh1jhjKhhhj0KhKubeh}(h]h ]h"]h$]h&]j j juh1hjjhjKhhhj0KhKubah}(h]jKah ](jjeh"]h$]h&]jj )j!huh1hhj0KhKhjKhhubj#)}(hhh]j<)}(hGet a relative duty cycle valueh]hGet a relative duty cycle value}(hjjLhhhNhNubah}(h]h ]h"]h$]h&]uh1j;h\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhKhjgLhhubah}(h]h ]h"]h$]h&]uh1j"hjKhhhj0KhKubeh}(h]h ](j0functioneh"]h$]h&]j5j0j6jLj7jLj8j9j:uh1hhhhj ?hNhNubjs)}(hX**Parameters** ``const struct pwm_state *state`` PWM state to extract the duty cycle from ``unsigned int scale`` target scale of the relative duty cycle **Description** This functions converts the absolute duty cycle stored in **state** (expressed in nanosecond) into a value relative to the period. For example if you want to get the duty_cycle expressed in percent, call: pwm_get_state(pwm, :c:type:`state`); duty = pwm_get_relative_duty_cycle(:c:type:`state`, 100); **Return** rounded relative duty cycle multiplied by **scale**h](j<)}(h**Parameters**h]j})}(hjLh]h Parameters}(hjLhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjLubah}(h]h ]h"]h$]h&]uh1j;h\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhKhjLubj)}(hhh](j)}(hK``const struct pwm_state *state`` PWM state to extract the duty cycle from h](j)}(h!``const struct pwm_state *state``h]jB)}(hjLh]hconst struct pwm_state *state}(hjLhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhjLubah}(h]h ]h"]h$]h&]uh1jh\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhKhjLubj)}(hhh]j<)}(h(PWM state to extract the duty cycle fromh]h(PWM state to extract the duty cycle from}(hjLhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hjLhKhjLubah}(h]h ]h"]h$]h&]uh1jhjLubeh}(h]h ]h"]h$]h&]uh1jhjLhKhjLubj)}(h?``unsigned int scale`` target scale of the relative duty cycle h](j)}(h``unsigned int scale``h]jB)}(hjLh]hunsigned int scale}(hjLhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhjLubah}(h]h ]h"]h$]h&]uh1jh\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhKhjLubj)}(hhh]j<)}(h'target scale of the relative duty cycleh]h'target scale of the relative duty cycle}(hjLhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hjLhKhjLubah}(h]h ]h"]h$]h&]uh1jhjLubeh}(h]h ]h"]h$]h&]uh1jhjLhKhjLubeh}(h]h ]h"]h$]h&]uh1jhjLubj<)}(h**Description**h]j})}(hjMh]h Description}(hj!MhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjMubah}(h]h ]h"]h$]h&]uh1j;h\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhKhjLubj<)}(hThis functions converts the absolute duty cycle stored in **state** (expressed in nanosecond) into a value relative to the period.h](h:This functions converts the absolute duty cycle stored in }(hj5MhhhNhNubj})}(h **state**h]hstate}(hj=MhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj5Mubh? (expressed in nanosecond) into a value relative to the period.}(hj5MhhhNhNubeh}(h]h ]h"]h$]h&]uh1j;h\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhKhjLubj<)}(hIFor example if you want to get the duty_cycle expressed in percent, call:h]hIFor example if you want to get the duty_cycle expressed in percent, call:}(hjVMhhhNhNubah}(h]h ]h"]h$]h&]uh1j;h\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhKhjLubj<)}(h^pwm_get_state(pwm, :c:type:`state`); duty = pwm_get_relative_duty_cycle(:c:type:`state`, 100);h](hpwm_get_state(pwm, }(hjeMhhhNhNubh)}(h:c:type:`state`h]jB)}(hjoMh]hstate}(hjqMhhhNhNubah}(h]h ](jA?j0c-typeeh"]h$]h&]uh1jAhjmMubah}(h]h ]h"]h$]h&]refdocjM? refdomainj0reftypetype refexplicitrefwarnjjS?jV?stateuh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhKhjeMubh&); duty = pwm_get_relative_duty_cycle(}(hjeMhhhNhNubh)}(h:c:type:`state`h]jB)}(hjMh]hstate}(hjMhhhNhNubah}(h]h ](jA?j0c-typeeh"]h$]h&]uh1jAhjMubah}(h]h ]h"]h$]h&]refdocjM? refdomainj0reftypetype refexplicitrefwarnjjS?jV?stateuh1hhjMhKhjeMubh, 100);}(hjeMhhhNhNubeh}(h]h ]h"]h$]h&]uh1j;hjMhKhjLubj<)}(h **Return**h]j})}(hjMh]hReturn}(hjMhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjMubah}(h]h ]h"]h$]h&]uh1j;h\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhKhjLubj<)}(h3rounded relative duty cycle multiplied by **scale**h](h*rounded relative duty cycle multiplied by }(hjMhhhNhNubj})}(h **scale**h]hscale}(hjMhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjMubeh}(h]h ]h"]h$]h&]uh1j;h\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhKhjLubeh}(h]h ] kernelindentah"]h$]h&]uh1jrhj ?hhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](h،(pwm_set_relative_duty_cycle (C function)c.pwm_set_relative_duty_cyclehNtauh1hhj ?hhhNhNubh)}(hhh](h)}(hfint pwm_set_relative_duty_cycle (struct pwm_state *state, unsigned int duty_cycle, unsigned int scale)h]h)}(heint pwm_set_relative_duty_cycle(struct pwm_state *state, unsigned int duty_cycle, unsigned int scale)h](j)}(hinth]hint}(hjNhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj Nhhh\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhKubj)}(h h]h }(hjNhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj NhhhjNhKubh)}(hpwm_set_relative_duty_cycleh]h)}(hpwm_set_relative_duty_cycleh]hpwm_set_relative_duty_cycle}(hj0NhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj,Nubah}(h]h ](jjeh"]h$]h&]j j uh1hhj NhhhjNhKubj)}(hF(struct pwm_state *state, unsigned int duty_cycle, unsigned int scale)h](j)}(hstruct pwm_state *stateh](j)}(hjh]hstruct}(hjLNhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjHNubj)}(h h]h }(hjYNhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjHNubh)}(hhh]h)}(h pwm_stateh]h pwm_state}(hjjNhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjgNubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetjlNmodnameN classnameNjj )}j]j)}jj2Nsbc.pwm_set_relative_duty_cycleasbuh1hhjHNubj)}(h h]h }(hjNhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjHNubj%)}(hj(h]h*}(hjNhhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hjHNubh)}(hstateh]hstate}(hjNhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjHNubeh}(h]h ]h"]h$]h&]noemphj j uh1jhjDNubj)}(hunsigned int duty_cycleh](j)}(hunsignedh]hunsigned}(hjNhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjNubj)}(h h]h }(hjNhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjNubj)}(hinth]hint}(hjNhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjNubj)}(h h]h }(hjNhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjNubh)}(h duty_cycleh]h duty_cycle}(hjNhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjNubeh}(h]h ]h"]h$]h&]noemphj j uh1jhjDNubj)}(hunsigned int scaleh](j)}(hunsignedh]hunsigned}(hjOhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj Oubj)}(h h]h }(hjOhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj Oubj)}(hinth]hint}(hj+OhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj Oubj)}(h h]h }(hj9OhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj Oubh)}(hscaleh]hscale}(hjGOhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj Oubeh}(h]h ]h"]h$]h&]noemphj j uh1jhjDNubeh}(h]h ]h"]h$]h&]j j uh1jhj NhhhjNhKubeh}(h]h ]h"]h$]h&]j j juh1hjjhjNhhhjNhKubah}(h]jNah ](jjeh"]h$]h&]jj )j!huh1hhjNhKhjNhhubj#)}(hhh]j<)}(hSet a relative duty cycle valueh]hSet a relative duty cycle value}(hjqOhhhNhNubah}(h]h ]h"]h$]h&]uh1j;h\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhKhjnOhhubah}(h]h ]h"]h$]h&]uh1j"hjNhhhjNhKubeh}(h]h ](j0functioneh"]h$]h&]j5j0j6jOj7jOj8j9j:uh1hhhhj ?hNhNubjs)}(hX**Parameters** ``struct pwm_state *state`` PWM state to fill ``unsigned int duty_cycle`` relative duty cycle value ``unsigned int scale`` scale in which **duty_cycle** is expressed **Description** This functions converts a relative into an absolute duty cycle (expressed in nanoseconds), and puts the result in state->duty_cycle. For example if you want to configure a 50% duty cycle, call: pwm_init_state(pwm, :c:type:`state`); pwm_set_relative_duty_cycle(:c:type:`state`, 50, 100); pwm_apply_might_sleep(pwm, :c:type:`state`); **Return** 0 on success or ``-EINVAL`` if **duty_cycle** and/or **scale** are inconsistent (**scale** == 0 or **duty_cycle** > **scale**)h](j<)}(h**Parameters**h]j})}(hjOh]h Parameters}(hjOhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjOubah}(h]h ]h"]h$]h&]uh1j;h\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhKhjOubj)}(hhh](j)}(h.``struct pwm_state *state`` PWM state to fill h](j)}(h``struct pwm_state *state``h]jB)}(hjOh]hstruct pwm_state *state}(hjOhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhjOubah}(h]h ]h"]h$]h&]uh1jh\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhKhjOubj)}(hhh]j<)}(hPWM state to fillh]hPWM state to fill}(hjOhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hjOhKhjOubah}(h]h ]h"]h$]h&]uh1jhjOubeh}(h]h ]h"]h$]h&]uh1jhjOhKhjOubj)}(h6``unsigned int duty_cycle`` relative duty cycle value h](j)}(h``unsigned int duty_cycle``h]jB)}(hjOh]hunsigned int duty_cycle}(hjOhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhjOubah}(h]h ]h"]h$]h&]uh1jh\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhKhjOubj)}(hhh]j<)}(hrelative duty cycle valueh]hrelative duty cycle value}(hjPhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hjPhKhjPubah}(h]h ]h"]h$]h&]uh1jhjOubeh}(h]h ]h"]h$]h&]uh1jhjPhKhjOubj)}(hB``unsigned int scale`` scale in which **duty_cycle** is expressed h](j)}(h``unsigned int scale``h]jB)}(hj$Ph]hunsigned int scale}(hj&PhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhj"Pubah}(h]h ]h"]h$]h&]uh1jh\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhKhjPubj)}(hhh]j<)}(h*scale in which **duty_cycle** is expressedh](hscale in which }(hj=PhhhNhNubj})}(h**duty_cycle**h]h duty_cycle}(hjEPhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj=Pubh is expressed}(hj=PhhhNhNubeh}(h]h ]h"]h$]h&]uh1j;hj9PhKhj:Pubah}(h]h ]h"]h$]h&]uh1jhjPubeh}(h]h ]h"]h$]h&]uh1jhj9PhKhjOubeh}(h]h ]h"]h$]h&]uh1jhjOubj<)}(h**Description**h]j})}(hjqPh]h Description}(hjsPhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjoPubah}(h]h ]h"]h$]h&]uh1j;h\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhKhjOubj<)}(hThis functions converts a relative into an absolute duty cycle (expressed in nanoseconds), and puts the result in state->duty_cycle.h]hThis functions converts a relative into an absolute duty cycle (expressed in nanoseconds), and puts the result in state->duty_cycle.}(hjPhhhNhNubah}(h]h ]h"]h$]h&]uh1j;h\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhKhjOubj<)}(h **scale**)h](h0 on success or }(hj5QhhhNhNubjB)}(h ``-EINVAL``h]h-EINVAL}(hj=QhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhj5Qubh if }(hj5QhhhNhNubj})}(h**duty_cycle**h]h duty_cycle}(hjOQhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj5Qubh and/or }(hj5QhhhNhNubj})}(h **scale**h]hscale}(hjaQhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj5Qubh are inconsistent (}(hj5QhhhNhNubj})}(h **scale**h]hscale}(hjsQhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj5Qubh == 0 or }(hj5QhhhNhNubj})}(h**duty_cycle**h]h duty_cycle}(hjQhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj5Qubh > }(hj5QhhhNhNubj})}(h **scale**h]hscale}(hjQhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj5Qubh)}(hj5QhhhNhNubeh}(h]h ]h"]h$]h&]uh1j;h\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhKhjOubeh}(h]h ] kernelindentah"]h$]h&]uh1jrhj ?hhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](h،pwm_capture (C struct) c.pwm_capturehNtauh1hhj ?hhhNhNubh)}(hhh](h)}(h pwm_captureh]h)}(hstruct pwm_captureh](j)}(hjh]hstruct}(hjQhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjQhhh\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhMubj)}(h h]h }(hjQhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjQhhhjQhMubh)}(h pwm_captureh]h)}(hjQh]h pwm_capture}(hjQhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjQubah}(h]h ](jjeh"]h$]h&]j j uh1hhjQhhhjQhMubeh}(h]h ]h"]h$]h&]j j juh1hjjhjQhhhjQhMubah}(h]jQah ](jjeh"]h$]h&]jj )j!huh1hhjQhMhjQhhubj#)}(hhh]j<)}(hPWM capture datah]hPWM capture data}(hjRhhhNhNubah}(h]h ]h"]h$]h&]uh1j;h\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhM hjRhhubah}(h]h ]h"]h$]h&]uh1j"hjQhhhjQhMubeh}(h]h ](j0structeh"]h$]h&]j5j0j6j*Rj7j*Rj8j9j:uh1hhhhj ?hNhNubjs)}(h **Definition**:: struct pwm_capture { unsigned int period; unsigned int duty_cycle; }; **Members** ``period`` period of the PWM signal (in nanoseconds) ``duty_cycle`` duty cycle of the PWM signal (in nanoseconds)h](jX)}(hl**Definition**:: struct pwm_capture { unsigned int period; unsigned int duty_cycle; }; h](j<)}(h**Definition**::h](j})}(h**Definition**h]h Definition}(hj:RhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj6Rubh:}(hj6RhhhNhNubeh}(h]h ]h"]h$]h&]uh1j;h\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhMhj2RubjVA)}(hQstruct pwm_capture { unsigned int period; unsigned int duty_cycle; };h]hQstruct pwm_capture { unsigned int period; unsigned int duty_cycle; };}hjSRsbah}(h]h ]h"]h$]h&]j j uh1jUAh\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhMhj2Rubeh}(h]h ]h"]h$]h&]uh1jWhjRRhMhj.Rubj<)}(h **Members**h]j})}(hjjRh]hMembers}(hjlRhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjhRubah}(h]h ]h"]h$]h&]uh1j;h\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhMhj.Rubj)}(hhh](j)}(h5``period`` period of the PWM signal (in nanoseconds) h](j)}(h ``period``h]jB)}(hjRh]hperiod}(hjRhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhjRubah}(h]h ]h"]h$]h&]uh1jh\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhMhjRubj)}(hhh]j<)}(h)period of the PWM signal (in nanoseconds)h]h)period of the PWM signal (in nanoseconds)}(hjRhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hjRhMhjRubah}(h]h ]h"]h$]h&]uh1jhjRubeh}(h]h ]h"]h$]h&]uh1jhjRhMhjRubj)}(h<``duty_cycle`` duty cycle of the PWM signal (in nanoseconds)h](j)}(h``duty_cycle``h]jB)}(hjRh]h duty_cycle}(hjRhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhjRubah}(h]h ]h"]h$]h&]uh1jh\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhMhjRubj)}(hhh]j<)}(h-duty cycle of the PWM signal (in nanoseconds)h]h-duty cycle of the PWM signal (in nanoseconds)}(hjRhhhNhNubah}(h]h ]h"]h$]h&]uh1j;h\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhMhjRubah}(h]h ]h"]h$]h&]uh1jhjRubeh}(h]h ]h"]h$]h&]uh1jhjRhMhjRubeh}(h]h ]h"]h$]h&]uh1jhj.Rubeh}(h]h ] kernelindentah"]h$]h&]uh1jrhj ?hhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](h،pwm_ops (C struct) c.pwm_opshNtauh1hhj ?hhhNhNubh)}(hhh](h)}(hpwm_opsh]h)}(hstruct pwm_opsh](j)}(hjh]hstruct}(hjShhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjShhh\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhMubj)}(h h]h }(hj*ShhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjShhhj)ShMubh)}(hpwm_opsh]h)}(hjSh]hpwm_ops}(hjVhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj,Vhhhj=VhM*ubh)}(hpwm_chiph]h)}(hj*Vh]hpwm_chip}(hjPVhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjLVubah}(h]h ](jjeh"]h$]h&]j j uh1hhj,Vhhhj=VhM*ubeh}(h]h ]h"]h$]h&]j j juh1hjjhj(Vhhhj=VhM*ubah}(h]j#Vah ](jjeh"]h$]h&]jj )j!huh1hhj=VhM*hj%Vhhubj#)}(hhh]j<)}(habstract a PWM controllerh]habstract a PWM controller}(hjrVhhhNhNubah}(h]h ]h"]h$]h&]uh1j;h\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhM<hjoVhhubah}(h]h ]h"]h$]h&]uh1j"hj%Vhhhj=VhM*ubeh}(h]h ](j0structeh"]h$]h&]j5j0j6jVj7jVj8j9j:uh1hhhhj ?hNhNubjs)}(hX **Definition**:: struct pwm_chip { struct device dev; struct cdev cdev; const struct pwm_ops *ops; struct module *owner; unsigned int id; unsigned int npwm; struct pwm_device * (*of_xlate)(struct pwm_chip *chip, const struct of_phandle_args *args); bool atomic; struct gpio_chip gpio; bool uses_pwmchip_alloc; bool operational; union { struct mutex nonatomic_lock; spinlock_t atomic_lock; }; struct pwm_device pwms[]; }; **Members** ``dev`` device providing the PWMs ``cdev`` :c:type:`struct cdev ` for this device ``ops`` callbacks for this PWM controller ``owner`` module providing this chip ``id`` unique number of this PWM chip ``npwm`` number of PWMs controlled by this chip ``of_xlate`` request a PWM device given a device tree PWM specifier ``atomic`` can the driver's ->apply() be called in atomic context ``gpio`` :c:type:`struct gpio_chip ` to operate this PWM chip's lines as GPO ``uses_pwmchip_alloc`` signals if pwmchip_allow was used to allocate this chip ``operational`` signals if the chip can be used (or is already deregistered) ``{unnamed_union}`` anonymous ``nonatomic_lock`` mutex for nonatomic chips ``atomic_lock`` mutex for atomic chips ``pwms`` array of PWM devices allocated by the frameworkh](jX)}(hX6**Definition**:: struct pwm_chip { struct device dev; struct cdev cdev; const struct pwm_ops *ops; struct module *owner; unsigned int id; unsigned int npwm; struct pwm_device * (*of_xlate)(struct pwm_chip *chip, const struct of_phandle_args *args); bool atomic; struct gpio_chip gpio; bool uses_pwmchip_alloc; bool operational; union { struct mutex nonatomic_lock; spinlock_t atomic_lock; }; struct pwm_device pwms[]; }; h](j<)}(h**Definition**::h](j})}(h**Definition**h]h Definition}(hjVhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjVubh:}(hjVhhhNhNubeh}(h]h ]h"]h$]h&]uh1j;h\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhM@hjVubjVA)}(hXstruct pwm_chip { struct device dev; struct cdev cdev; const struct pwm_ops *ops; struct module *owner; unsigned int id; unsigned int npwm; struct pwm_device * (*of_xlate)(struct pwm_chip *chip, const struct of_phandle_args *args); bool atomic; struct gpio_chip gpio; bool uses_pwmchip_alloc; bool operational; union { struct mutex nonatomic_lock; spinlock_t atomic_lock; }; struct pwm_device pwms[]; };h]hXstruct pwm_chip { struct device dev; struct cdev cdev; const struct pwm_ops *ops; struct module *owner; unsigned int id; unsigned int npwm; struct pwm_device * (*of_xlate)(struct pwm_chip *chip, const struct of_phandle_args *args); bool atomic; struct gpio_chip gpio; bool uses_pwmchip_alloc; bool operational; union { struct mutex nonatomic_lock; spinlock_t atomic_lock; }; struct pwm_device pwms[]; };}hjVsbah}(h]h ]h"]h$]h&]j j uh1jUAh\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhMBhjVubeh}(h]h ]h"]h$]h&]uh1jWhjVhM@hjVubj<)}(h **Members**h]j})}(hjVh]hMembers}(hjVhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjVubah}(h]h ]h"]h$]h&]uh1j;h\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhMUhjVubj)}(hhh](j)}(h"``dev`` device providing the PWMs h](j)}(h``dev``h]jB)}(hjVh]hdev}(hjVhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhjVubah}(h]h ]h"]h$]h&]uh1jh\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhM>hjVubj)}(hhh]j<)}(hdevice providing the PWMsh]hdevice providing the PWMs}(hjWhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hjVhM>hjVubah}(h]h ]h"]h$]h&]uh1jhjVubeh}(h]h ]h"]h$]h&]uh1jhjVhM>hjVubj)}(h6``cdev`` :c:type:`struct cdev ` for this device h](j)}(h``cdev``h]jB)}(hj"Wh]hcdev}(hj$WhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhj Wubah}(h]h ]h"]h$]h&]uh1jh\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhM?hjWubj)}(hhh]j<)}(h,:c:type:`struct cdev ` for this deviceh](h)}(h:c:type:`struct cdev `h]jB)}(hjAWh]h struct cdev}(hjCWhhhNhNubah}(h]h ](jA?j0c-typeeh"]h$]h&]uh1jAhj?Wubah}(h]h ]h"]h$]h&]refdocjM? refdomainj0reftypetype refexplicitrefwarnjjS?jV?cdevuh1hhj7WhM?hj;Wubh for this device}(hj;WhhhNhNubeh}(h]h ]h"]h$]h&]uh1j;hj7WhM?hj8Wubah}(h]h ]h"]h$]h&]uh1jhjWubeh}(h]h ]h"]h$]h&]uh1jhj7WhM?hjVubj)}(h*``ops`` callbacks for this PWM controller h](j)}(h``ops``h]jB)}(hjzWh]hops}(hj|WhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhjxWubah}(h]h ]h"]h$]h&]uh1jh\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhM@hjtWubj)}(hhh]j<)}(h!callbacks for this PWM controllerh]h!callbacks for this PWM controller}(hjWhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hjWhM@hjWubah}(h]h ]h"]h$]h&]uh1jhjtWubeh}(h]h ]h"]h$]h&]uh1jhjWhM@hjVubj)}(h%``owner`` module providing this chip h](j)}(h ``owner``h]jB)}(hjWh]howner}(hjWhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhjWubah}(h]h ]h"]h$]h&]uh1jh\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhMAhjWubj)}(hhh]j<)}(hmodule providing this chiph]hmodule providing this chip}(hjWhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hjWhMAhjWubah}(h]h ]h"]h$]h&]uh1jhjWubeh}(h]h ]h"]h$]h&]uh1jhjWhMAhjVubj)}(h&``id`` unique number of this PWM chip h](j)}(h``id``h]jB)}(hjWh]hid}(hjWhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhjWubah}(h]h ]h"]h$]h&]uh1jh\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhMBhjWubj)}(hhh]j<)}(hunique number of this PWM chiph]hunique number of this PWM chip}(hjXhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hjXhMBhjXubah}(h]h ]h"]h$]h&]uh1jhjWubeh}(h]h ]h"]h$]h&]uh1jhjXhMBhjVubj)}(h0``npwm`` number of PWMs controlled by this chip h](j)}(h``npwm``h]jB)}(hj%Xh]hnpwm}(hj'XhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhj#Xubah}(h]h ]h"]h$]h&]uh1jh\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhMChjXubj)}(hhh]j<)}(h&number of PWMs controlled by this chiph]h&number of PWMs controlled by this chip}(hj>XhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hj:XhMChj;Xubah}(h]h ]h"]h$]h&]uh1jhjXubeh}(h]h ]h"]h$]h&]uh1jhj:XhMChjVubj)}(hD``of_xlate`` request a PWM device given a device tree PWM specifier h](j)}(h ``of_xlate``h]jB)}(hj^Xh]hof_xlate}(hj`XhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhj\Xubah}(h]h ]h"]h$]h&]uh1jh\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhMDhjXXubj)}(hhh]j<)}(h6request a PWM device given a device tree PWM specifierh]h6request a PWM device given a device tree PWM specifier}(hjwXhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hjsXhMDhjtXubah}(h]h ]h"]h$]h&]uh1jhjXXubeh}(h]h ]h"]h$]h&]uh1jhjsXhMDhjVubj)}(hB``atomic`` can the driver's ->apply() be called in atomic context h](j)}(h ``atomic``h]jB)}(hjXh]hatomic}(hjXhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhjXubah}(h]h ]h"]h$]h&]uh1jh\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhMEhjXubj)}(hhh]j<)}(h6can the driver's ->apply() be called in atomic contexth]h8can the driver’s ->apply() be called in atomic context}(hjXhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hjXhMEhjXubah}(h]h ]h"]h$]h&]uh1jhjXubeh}(h]h ]h"]h$]h&]uh1jhjXhMEhjVubj)}(hX``gpio`` :c:type:`struct gpio_chip ` to operate this PWM chip's lines as GPO h](j)}(h``gpio``h]jB)}(hjXh]hgpio}(hjXhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhjXubah}(h]h ]h"]h$]h&]uh1jh\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhMFhjXubj)}(hhh]j<)}(hN:c:type:`struct gpio_chip ` to operate this PWM chip's lines as GPOh](h)}(h&:c:type:`struct gpio_chip `h]jB)}(hjXh]hstruct gpio_chip}(hjXhhhNhNubah}(h]h ](jA?j0c-typeeh"]h$]h&]uh1jAhjXubah}(h]h ]h"]h$]h&]refdocjM? refdomainj0reftypetype refexplicitrefwarnjjS?jV? gpio_chipuh1hhjXhMFhjXubh* to operate this PWM chip’s lines as GPO}(hjXhhhNhNubeh}(h]h ]h"]h$]h&]uh1j;hjXhMFhjXubah}(h]h ]h"]h$]h&]uh1jhjXubeh}(h]h ]h"]h$]h&]uh1jhjXhMFhjVubj)}(hO``uses_pwmchip_alloc`` signals if pwmchip_allow was used to allocate this chip h](j)}(h``uses_pwmchip_alloc``h]jB)}(hj(Yh]huses_pwmchip_alloc}(hj*YhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhj&Yubah}(h]h ]h"]h$]h&]uh1jh\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhMGhj"Yubj)}(hhh]j<)}(h7signals if pwmchip_allow was used to allocate this chiph]h7signals if pwmchip_allow was used to allocate this chip}(hjAYhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hj=YhMGhj>Yubah}(h]h ]h"]h$]h&]uh1jhj"Yubeh}(h]h ]h"]h$]h&]uh1jhj=YhMGhjVubj)}(hM``operational`` signals if the chip can be used (or is already deregistered) h](j)}(h``operational``h]jB)}(hjaYh]h operational}(hjcYhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhj_Yubah}(h]h ]h"]h$]h&]uh1jh\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhMHhj[Yubj)}(hhh]j<)}(hfalse if pwm_apply_atomic() can be called from atomic context.h]h>false if pwm_apply_atomic() can be called from atomic context.}(hjbhhhNhNubah}(h]h ]h"]h$]h&]uh1j;h\/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:44: ./include/linux/pwm.hhMhj4bubeh}(h]h ] kernelindentah"]h$]h&]uh1jrhj ?hhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](h،+pwm_round_waveform_might_sleep (C function) c.pwm_round_waveform_might_sleephNtauh1hhj ?hhhNhNubh)}(hhh](h)}(hTint pwm_round_waveform_might_sleep (struct pwm_device *pwm, struct pwm_waveform *wf)h]h)}(hSint pwm_round_waveform_might_sleep(struct pwm_device *pwm, struct pwm_waveform *wf)h](j)}(hinth]hint}(hjbhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjbhhh[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chKubj)}(h h]h }(hjbhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjbhhhjbhKubh)}(hpwm_round_waveform_might_sleeph]h)}(hpwm_round_waveform_might_sleeph]hpwm_round_waveform_might_sleep}(hjbhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjbubah}(h]h ](jjeh"]h$]h&]j j uh1hhjbhhhjbhKubj)}(h1(struct pwm_device *pwm, struct pwm_waveform *wf)h](j)}(hstruct pwm_device *pwmh](j)}(hjh]hstruct}(hjchhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjcubj)}(h h]h }(hj#chhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjcubh)}(hhh]h)}(h pwm_deviceh]h pwm_device}(hj4chhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj1cubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetj6cmodnameN classnameNjj )}j]j)}jjbsb c.pwm_round_waveform_might_sleepasbuh1hhjcubj)}(h h]h }(hjTchhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjcubj%)}(hj(h]h*}(hjbchhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hjcubh)}(hpwmh]hpwm}(hjochhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjcubeh}(h]h ]h"]h$]h&]noemphj j uh1jhjcubj)}(hstruct pwm_waveform *wfh](j)}(hjh]hstruct}(hjchhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjcubj)}(h h]h }(hjchhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjcubh)}(hhh]h)}(h pwm_waveformh]h pwm_waveform}(hjchhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjcubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetjcmodnameN classnameNjj )}j]jPc c.pwm_round_waveform_might_sleepasbuh1hhjcubj)}(h h]h }(hjchhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjcubj%)}(hj(h]h*}(hjchhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hjcubh)}(hwfh]hwf}(hjchhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjcubeh}(h]h ]h"]h$]h&]noemphj j uh1jhjcubeh}(h]h ]h"]h$]h&]j j uh1jhjbhhhjbhKubeh}(h]h ]h"]h$]h&]j j juh1hjjhjbhhhjbhKubah}(h]jbah ](jjeh"]h$]h&]jj )j!huh1hhjbhKhjbhhubj#)}(hhh]j<)}(h=Query hardware capabilities Cannot be used in atomic context.h]h=Query hardware capabilities Cannot be used in atomic context.}(hj dhhhNhNubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chKhjdhhubah}(h]h ]h"]h$]h&]uh1j"hjbhhhjbhKubeh}(h]h ](j0functioneh"]h$]h&]j5j0j6j!dj7j!dj8j9j:uh1hhhhj ?hNhNubjs)}(hX**Parameters** ``struct pwm_device *pwm`` PWM device ``struct pwm_waveform *wf`` waveform to round and output parameter **Description** Typically a given waveform cannot be implemented exactly by hardware, e.g. because hardware only supports coarse period resolution or no duty_offset. This function returns the actually implemented waveform if you pass **wf** to pwm_set_waveform_might_sleep() now. Note however that the world doesn't stop turning when you call it, so when doing:: pwm_round_waveform_might_sleep(mypwm, &wf); pwm_set_waveform_might_sleep(mypwm, &wf, true); the latter might fail, e.g. because an input clock changed its rate between these two calls and the waveform determined by pwm_round_waveform_might_sleep() cannot be implemented any more. Usually all values passed in **wf** are rounded down to the nearest possible value (in the order period_length_ns, duty_length_ns and then duty_offset_ns). Only if this isn't possible, a value might grow. See the documentation for pwm_set_waveform_might_sleep() for a more formal description. **Return** 0 on success, 1 if at least one value had to be rounded up or a negative errno. **Context** May sleep.h](j<)}(h**Parameters**h]j})}(hj+dh]h Parameters}(hj-dhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj)dubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chKhj%dubj)}(hhh](j)}(h&``struct pwm_device *pwm`` PWM device h](j)}(h``struct pwm_device *pwm``h]jB)}(hjJdh]hstruct pwm_device *pwm}(hjLdhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhjHdubah}(h]h ]h"]h$]h&]uh1jh[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chKhjDdubj)}(hhh]j<)}(h PWM deviceh]h PWM device}(hjcdhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hj_dhKhj`dubah}(h]h ]h"]h$]h&]uh1jhjDdubeh}(h]h ]h"]h$]h&]uh1jhj_dhKhjAdubj)}(hC``struct pwm_waveform *wf`` waveform to round and output parameter h](j)}(h``struct pwm_waveform *wf``h]jB)}(hjdh]hstruct pwm_waveform *wf}(hjdhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhjdubah}(h]h ]h"]h$]h&]uh1jh[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chKhj}dubj)}(hhh]j<)}(h&waveform to round and output parameterh]h&waveform to round and output parameter}(hjdhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hjdhKhjdubah}(h]h ]h"]h$]h&]uh1jhj}dubeh}(h]h ]h"]h$]h&]uh1jhjdhKhjAdubeh}(h]h ]h"]h$]h&]uh1jhj%dubj<)}(h**Description**h]j})}(hjdh]h Description}(hjdhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjdubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chKhj%dubj<)}(hXTypically a given waveform cannot be implemented exactly by hardware, e.g. because hardware only supports coarse period resolution or no duty_offset. This function returns the actually implemented waveform if you pass **wf** to pwm_set_waveform_might_sleep() now.h](hTypically a given waveform cannot be implemented exactly by hardware, e.g. because hardware only supports coarse period resolution or no duty_offset. This function returns the actually implemented waveform if you pass }(hjdhhhNhNubj})}(h**wf**h]hwf}(hjdhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjdubh' to pwm_set_waveform_might_sleep() now.}(hjdhhhNhNubeh}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chKhj%dubj<)}(hRNote however that the world doesn't stop turning when you call it, so when doing::h]hSNote however that the world doesn’t stop turning when you call it, so when doing:}(hjdhhhNhNubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chKhj%dubjVA)}(h[pwm_round_waveform_might_sleep(mypwm, &wf); pwm_set_waveform_might_sleep(mypwm, &wf, true);h]h[pwm_round_waveform_might_sleep(mypwm, &wf); pwm_set_waveform_might_sleep(mypwm, &wf, true);}hjesbah}(h]h ]h"]h$]h&]j j uh1jUAh[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chKhj%dubj<)}(hthe latter might fail, e.g. because an input clock changed its rate between these two calls and the waveform determined by pwm_round_waveform_might_sleep() cannot be implemented any more.h]hthe latter might fail, e.g. because an input clock changed its rate between these two calls and the waveform determined by pwm_round_waveform_might_sleep() cannot be implemented any more.}(hjehhhNhNubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chKhj%dubj<)}(hX$Usually all values passed in **wf** are rounded down to the nearest possible value (in the order period_length_ns, duty_length_ns and then duty_offset_ns). Only if this isn't possible, a value might grow. See the documentation for pwm_set_waveform_might_sleep() for a more formal description.h](hUsually all values passed in }(hj"ehhhNhNubj})}(h**wf**h]hwf}(hj*ehhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj"eubhX are rounded down to the nearest possible value (in the order period_length_ns, duty_length_ns and then duty_offset_ns). Only if this isn’t possible, a value might grow. See the documentation for pwm_set_waveform_might_sleep() for a more formal description.}(hj"ehhhNhNubeh}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chKhj%dubj<)}(h **Return**h]j})}(hjEeh]hReturn}(hjGehhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjCeubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chKhj%dubj<)}(hO0 on success, 1 if at least one value had to be rounded up or a negative errno.h]hO0 on success, 1 if at least one value had to be rounded up or a negative errno.}(hj[ehhhNhNubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chKhj%dubj<)}(h **Context**h]j})}(hjleh]hContext}(hjnehhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjjeubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chKhj%dubj<)}(h May sleep.h]h May sleep.}(hjehhhNhNubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chKhj%dubeh}(h]h ] kernelindentah"]h$]h&]uh1jrhj ?hhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](h،)pwm_get_waveform_might_sleep (C function)c.pwm_get_waveform_might_sleephNtauh1hhj ?hhhNhNubh)}(hhh](h)}(hRint pwm_get_waveform_might_sleep (struct pwm_device *pwm, struct pwm_waveform *wf)h]h)}(hQint pwm_get_waveform_might_sleep(struct pwm_device *pwm, struct pwm_waveform *wf)h](j)}(hinth]hint}(hjehhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjehhh[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chM$ubj)}(h h]h }(hjehhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjehhhjehM$ubh)}(hpwm_get_waveform_might_sleeph]h)}(hpwm_get_waveform_might_sleeph]hpwm_get_waveform_might_sleep}(hjehhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjeubah}(h]h ](jjeh"]h$]h&]j j uh1hhjehhhjehM$ubj)}(h1(struct pwm_device *pwm, struct pwm_waveform *wf)h](j)}(hstruct pwm_device *pwmh](j)}(hjh]hstruct}(hjehhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjeubj)}(h h]h }(hjehhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjeubh)}(hhh]h)}(h pwm_deviceh]h pwm_device}(hj fhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj fubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetjfmodnameN classnameNjj )}j]j)}jjesbc.pwm_get_waveform_might_sleepasbuh1hhjeubj)}(h h]h }(hj,fhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjeubj%)}(hj(h]h*}(hj:fhhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hjeubh)}(hpwmh]hpwm}(hjGfhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjeubeh}(h]h ]h"]h$]h&]noemphj j uh1jhjeubj)}(hstruct pwm_waveform *wfh](j)}(hjh]hstruct}(hj`fhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj\fubj)}(h h]h }(hjmfhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj\fubh)}(hhh]h)}(h pwm_waveformh]h pwm_waveform}(hj~fhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj{fubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetjfmodnameN classnameNjj )}j]j(fc.pwm_get_waveform_might_sleepasbuh1hhj\fubj)}(h h]h }(hjfhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj\fubj%)}(hj(h]h*}(hjfhhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hj\fubh)}(hwfh]hwf}(hjfhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj\fubeh}(h]h ]h"]h$]h&]noemphj j uh1jhjeubeh}(h]h ]h"]h$]h&]j j uh1jhjehhhjehM$ubeh}(h]h ]h"]h$]h&]j j juh1hjjhjehhhjehM$ubah}(h]jeah ](jjeh"]h$]h&]jj )j!huh1hhjehM$hjehhubj#)}(hhh]j<)}(hLQuery hardware about current configuration Cannot be used in atomic context.h]hLQuery hardware about current configuration Cannot be used in atomic context.}(hjfhhhNhNubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chM$hjfhhubah}(h]h ]h"]h$]h&]uh1j"hjehhhjehM$ubeh}(h]h ](j0functioneh"]h$]h&]j5j0j6jfj7jfj8j9j:uh1hhhhj ?hNhNubjs)}(hXU**Parameters** ``struct pwm_device *pwm`` PWM device ``struct pwm_waveform *wf`` output parameter **Description** Stores the current configuration of the PWM in **wf**. Note this is the equivalent of pwm_get_state_hw() (and not pwm_get_state()) for pwm_waveform. **Return** 0 on success or a negative errno **Context** May sleep.h](j<)}(h**Parameters**h]j})}(hjgh]h Parameters}(hjghhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjgubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chM(hjfubj)}(hhh](j)}(h&``struct pwm_device *pwm`` PWM device h](j)}(h``struct pwm_device *pwm``h]jB)}(hj"gh]hstruct pwm_device *pwm}(hj$ghhhNhNubah}(h]h ]h"]h$]h&]uh1jAhj gubah}(h]h ]h"]h$]h&]uh1jh[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chM&hjgubj)}(hhh]j<)}(h PWM deviceh]h PWM device}(hj;ghhhNhNubah}(h]h ]h"]h$]h&]uh1j;hj7ghM&hj8gubah}(h]h ]h"]h$]h&]uh1jhjgubeh}(h]h ]h"]h$]h&]uh1jhj7ghM&hjgubj)}(h-``struct pwm_waveform *wf`` output parameter h](j)}(h``struct pwm_waveform *wf``h]jB)}(hj[gh]hstruct pwm_waveform *wf}(hj]ghhhNhNubah}(h]h ]h"]h$]h&]uh1jAhjYgubah}(h]h ]h"]h$]h&]uh1jh[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chM'hjUgubj)}(hhh]j<)}(houtput parameterh]houtput parameter}(hjtghhhNhNubah}(h]h ]h"]h$]h&]uh1j;hjpghM'hjqgubah}(h]h ]h"]h$]h&]uh1jhjUgubeh}(h]h ]h"]h$]h&]uh1jhjpghM'hjgubeh}(h]h ]h"]h$]h&]uh1jhjfubj<)}(h**Description**h]j})}(hjgh]h Description}(hjghhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjgubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chM)hjfubj<)}(hStores the current configuration of the PWM in **wf**. Note this is the equivalent of pwm_get_state_hw() (and not pwm_get_state()) for pwm_waveform.h](h/Stores the current configuration of the PWM in }(hjghhhNhNubj})}(h**wf**h]hwf}(hjghhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjgubh_. Note this is the equivalent of pwm_get_state_hw() (and not pwm_get_state()) for pwm_waveform.}(hjghhhNhNubeh}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chM(hjfubj<)}(h **Return**h]j})}(hjgh]hReturn}(hjghhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjgubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chM+hjfubj<)}(h 0 on success or a negative errnoh]h 0 on success or a negative errno}(hjghhhNhNubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chM,hjfubj<)}(h **Context**h]j})}(hjgh]hContext}(hjghhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjgubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chM.hjfubj<)}(h May sleep.h]h May sleep.}(hj hhhhNhNubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chM-hjfubeh}(h]h ] kernelindentah"]h$]h&]uh1jrhj ?hhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](h،)pwm_set_waveform_might_sleep (C function)c.pwm_set_waveform_might_sleephNtauh1hhj ?hhhNhNubh)}(hhh](h)}(hdint pwm_set_waveform_might_sleep (struct pwm_device *pwm, const struct pwm_waveform *wf, bool exact)h]h)}(hcint pwm_set_waveform_might_sleep(struct pwm_device *pwm, const struct pwm_waveform *wf, bool exact)h](j)}(hinth]hint}(hj;hhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj7hhhh[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMubj)}(h h]h }(hjJhhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj7hhhhjIhhMubh)}(hpwm_set_waveform_might_sleeph]h)}(hpwm_set_waveform_might_sleeph]hpwm_set_waveform_might_sleep}(hj\hhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjXhubah}(h]h ](jjeh"]h$]h&]j j uh1hhj7hhhhjIhhMubj)}(hC(struct pwm_device *pwm, const struct pwm_waveform *wf, bool exact)h](j)}(hstruct pwm_device *pwmh](j)}(hjh]hstruct}(hjxhhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjthubj)}(h h]h }(hjhhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjthubh)}(hhh]h)}(h pwm_deviceh]h pwm_device}(hjhhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjhubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetjhmodnameN classnameNjj )}j]j)}jj^hsbc.pwm_set_waveform_might_sleepasbuh1hhjthubj)}(h h]h }(hjhhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjthubj%)}(hj(h]h*}(hjhhhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hjthubh)}(hpwmh]hpwm}(hjhhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjthubeh}(h]h ]h"]h$]h&]noemphj j uh1jhjphubj)}(hconst struct pwm_waveform *wfh](j)}(hjh]hconst}(hjhhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjhubj)}(h h]h }(hjhhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjhubj)}(hjh]hstruct}(hjihhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjhubj)}(h h]h }(hjihhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjhubh)}(hhh]h)}(h pwm_waveformh]h pwm_waveform}(hj#ihhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj iubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetj%imodnameN classnameNjj )}j]jhc.pwm_set_waveform_might_sleepasbuh1hhjhubj)}(h h]h }(hjAihhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjhubj%)}(hj(h]h*}(hjOihhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hjhubh)}(hwfh]hwf}(hj\ihhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjhubeh}(h]h ]h"]h$]h&]noemphj j uh1jhjphubj)}(h bool exacth](j)}(hjZh]hbool}(hjuihhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjqiubj)}(h h]h }(hjihhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjqiubh)}(hexacth]hexact}(hjihhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjqiubeh}(h]h ]h"]h$]h&]noemphj j uh1jhjphubeh}(h]h ]h"]h$]h&]j j uh1jhj7hhhhjIhhMubeh}(h]h ]h"]h$]h&]j j juh1hjjhj3hhhhjIhhMubah}(h]j.hah ](jjeh"]h$]h&]jj )j!huh1hhjIhhMhj0hhhubj#)}(hhh]j<)}(h6Apply a new waveform Cannot be used in atomic context.h]h6Apply a new waveform Cannot be used in atomic context.}(hjihhhNhNubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMhjihhubah}(h]h ]h"]h$]h&]uh1j"hj0hhhhjIhhMubeh}(h]h ](j0functioneh"]h$]h&]j5j0j6jij7jij8j9j:uh1hhhhj ?hNhNubjs)}(hX**Parameters** ``struct pwm_device *pwm`` PWM device ``const struct pwm_waveform *wf`` The waveform to apply ``bool exact`` If true no rounding is allowed **Description** Typically a requested waveform cannot be implemented exactly, e.g. because you requested .period_length_ns = 100 ns, but the hardware can only set periods that are a multiple of 8.5 ns. With that hardware passing **exact** = true results in pwm_set_waveform_might_sleep() failing and returning -EDOM. If **exact** = false you get a period of 93.5 ns (i.e. the biggest period not bigger than the requested value). Note that even with **exact** = true, some rounding by less than 1 ns is possible/needed. In the above example requesting .period_length_ns = 94 and **exact** = true, you get the hardware configured with period = 93.5 ns. Let C be the set of possible hardware configurations for a given PWM device, consisting of tuples (p, d, o) where p is the period length, d is the duty length and o the duty offset. The following algorithm is implemented to pick the hardware setting (p, d, o) ∈ C for a given request (p', d', o') with **exact** = false:: p = max( { ṗ | ∃ ḋ, ȯ : (ṗ, ḋ, ȯ) ∈ C ∧ ṗ ≤ p' } ∪ { min({ ṗ | ∃ ḋ, ȯ : (ṗ, ḋ, ȯ) ∈ C }) }) d = max( { ḋ | ∃ ȯ : (p, ḋ, ȯ) ∈ C ∧ ḋ ≤ d' } ∪ { min({ ḋ | ∃ ȯ : (p, ḋ, ȯ) ∈ C }) }) o = max( { ȯ | (p, d, ȯ) ∈ C ∧ ȯ ≤ o' } ∪ { min({ ȯ | (p, d, ȯ) ∈ C }) }) In words: The chosen period length is the maximal possible period length not bigger than the requested period length and if that doesn't exist, the minimal period length. The chosen duty length is the maximal possible duty length that is compatible with the chosen period length and isn't bigger than the requested duty length. Again if such a value doesn't exist, the minimal duty length compatible with the chosen period is picked. After that the duty offset compatible with the chosen period and duty length is chosen in the same way. **Return** 0 on success, -EDOM if setting failed due to the exact waveform not being possible (if **exact**), or a different negative errno on failure. **Context** May sleep.h](j<)}(h**Parameters**h]j})}(hjih]h Parameters}(hjihhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjiubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMhjiubj)}(hhh](j)}(h&``struct pwm_device *pwm`` PWM device h](j)}(h``struct pwm_device *pwm``h]jB)}(hjih]hstruct pwm_device *pwm}(hjihhhNhNubah}(h]h ]h"]h$]h&]uh1jAhjiubah}(h]h ]h"]h$]h&]uh1jh[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMhjiubj)}(hhh]j<)}(h PWM deviceh]h PWM device}(hjjhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hjjhMhjjubah}(h]h ]h"]h$]h&]uh1jhjiubeh}(h]h ]h"]h$]h&]uh1jhjjhMhjiubj)}(h8``const struct pwm_waveform *wf`` The waveform to apply h](j)}(h!``const struct pwm_waveform *wf``h]jB)}(hj4jh]hconst struct pwm_waveform *wf}(hj6jhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhj2jubah}(h]h ]h"]h$]h&]uh1jh[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMhj.jubj)}(hhh]j<)}(hThe waveform to applyh]hThe waveform to apply}(hjMjhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hjIjhMhjJjubah}(h]h ]h"]h$]h&]uh1jhj.jubeh}(h]h ]h"]h$]h&]uh1jhjIjhMhjiubj)}(h.``bool exact`` If true no rounding is allowed h](j)}(h``bool exact``h]jB)}(hjmjh]h bool exact}(hjojhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhjkjubah}(h]h ]h"]h$]h&]uh1jh[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMhjgjubj)}(hhh]j<)}(hIf true no rounding is allowedh]hIf true no rounding is allowed}(hjjhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hjjhMhjjubah}(h]h ]h"]h$]h&]uh1jhjgjubeh}(h]h ]h"]h$]h&]uh1jhjjhMhjiubeh}(h]h ]h"]h$]h&]uh1jhjiubj<)}(h**Description**h]j})}(hjjh]h Description}(hjjhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjjubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMhjiubj<)}(hXzTypically a requested waveform cannot be implemented exactly, e.g. because you requested .period_length_ns = 100 ns, but the hardware can only set periods that are a multiple of 8.5 ns. With that hardware passing **exact** = true results in pwm_set_waveform_might_sleep() failing and returning -EDOM. If **exact** = false you get a period of 93.5 ns (i.e. the biggest period not bigger than the requested value). Note that even with **exact** = true, some rounding by less than 1 ns is possible/needed. In the above example requesting .period_length_ns = 94 and **exact** = true, you get the hardware configured with period = 93.5 ns.h](hTypically a requested waveform cannot be implemented exactly, e.g. because you requested .period_length_ns = 100 ns, but the hardware can only set periods that are a multiple of 8.5 ns. With that hardware passing }(hjjhhhNhNubj})}(h **exact**h]hexact}(hjjhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjjubhR = true results in pwm_set_waveform_might_sleep() failing and returning -EDOM. If }(hjjhhhNhNubj})}(h **exact**h]hexact}(hjjhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjjubhx = false you get a period of 93.5 ns (i.e. the biggest period not bigger than the requested value). Note that even with }(hjjhhhNhNubj})}(h **exact**h]hexact}(hjjhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjjubhx = true, some rounding by less than 1 ns is possible/needed. In the above example requesting .period_length_ns = 94 and }(hjjhhhNhNubj})}(h **exact**h]hexact}(hjjhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjjubh? = true, you get the hardware configured with period = 93.5 ns.}(hjjhhhNhNubeh}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMhjiubj<)}(hLet C be the set of possible hardware configurations for a given PWM device, consisting of tuples (p, d, o) where p is the period length, d is the duty length and o the duty offset.h]hLet C be the set of possible hardware configurations for a given PWM device, consisting of tuples (p, d, o) where p is the period length, d is the duty length and o the duty offset.}(hjkhhhNhNubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMhjiubj<)}(hThe following algorithm is implemented to pick the hardware setting (p, d, o) ∈ C for a given request (p', d', o') with **exact** = false::h](hThe following algorithm is implemented to pick the hardware setting (p, d, o) ∈ C for a given request (p’, d’, o’) with }(hj$khhhNhNubj})}(h **exact**h]hexact}(hj,khhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj$kubh = false:}(hj$khhhNhNubeh}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMhjiubjVA)}(hXJp = max( { ṗ | ∃ ḋ, ȯ : (ṗ, ḋ, ȯ) ∈ C ∧ ṗ ≤ p' } ∪ { min({ ṗ | ∃ ḋ, ȯ : (ṗ, ḋ, ȯ) ∈ C }) }) d = max( { ḋ | ∃ ȯ : (p, ḋ, ȯ) ∈ C ∧ ḋ ≤ d' } ∪ { min({ ḋ | ∃ ȯ : (p, ḋ, ȯ) ∈ C }) }) o = max( { ȯ | (p, d, ȯ) ∈ C ∧ ȯ ≤ o' } ∪ { min({ ȯ | (p, d, ȯ) ∈ C }) })h]hXJp = max( { ṗ | ∃ ḋ, ȯ : (ṗ, ḋ, ȯ) ∈ C ∧ ṗ ≤ p' } ∪ { min({ ṗ | ∃ ḋ, ȯ : (ṗ, ḋ, ȯ) ∈ C }) }) d = max( { ḋ | ∃ ȯ : (p, ḋ, ȯ) ∈ C ∧ ḋ ≤ d' } ∪ { min({ ḋ | ∃ ȯ : (p, ḋ, ȯ) ∈ C }) }) o = max( { ȯ | (p, d, ȯ) ∈ C ∧ ȯ ≤ o' } ∪ { min({ ȯ | (p, d, ȯ) ∈ C }) })}hjEksbah}(h]h ]h"]h$]h&]j j uh1jUAh[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMhjiubj<)}(hXIn words: The chosen period length is the maximal possible period length not bigger than the requested period length and if that doesn't exist, the minimal period length. The chosen duty length is the maximal possible duty length that is compatible with the chosen period length and isn't bigger than the requested duty length. Again if such a value doesn't exist, the minimal duty length compatible with the chosen period is picked. After that the duty offset compatible with the chosen period and duty length is chosen in the same way.h]hXIn words: The chosen period length is the maximal possible period length not bigger than the requested period length and if that doesn’t exist, the minimal period length. The chosen duty length is the maximal possible duty length that is compatible with the chosen period length and isn’t bigger than the requested duty length. Again if such a value doesn’t exist, the minimal duty length compatible with the chosen period is picked. After that the duty offset compatible with the chosen period and duty length is chosen in the same way.}(hjTkhhhNhNubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMhjiubj<)}(h **Return**h]j})}(hjekh]hReturn}(hjgkhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjckubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMhjiubj<)}(h0 on success, -EDOM if setting failed due to the exact waveform not being possible (if **exact**), or a different negative errno on failure.h](hW0 on success, -EDOM if setting failed due to the exact waveform not being possible (if }(hj{khhhNhNubj})}(h **exact**h]hexact}(hjkhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj{kubh,), or a different negative errno on failure.}(hj{khhhNhNubeh}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMhjiubj<)}(h **Context**h]j})}(hjkh]hContext}(hjkhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjkubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMhjiubj<)}(h May sleep.h]h May sleep.}(hjkhhhNhNubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMhjiubeh}(h]h ] kernelindentah"]h$]h&]uh1jrhj ?hhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](h،"pwm_apply_might_sleep (C function)c.pwm_apply_might_sleephNtauh1hhj ?hhhNhNubh)}(hhh](h)}(hQint pwm_apply_might_sleep (struct pwm_device *pwm, const struct pwm_state *state)h]h)}(hPint pwm_apply_might_sleep(struct pwm_device *pwm, const struct pwm_state *state)h](j)}(hinth]hint}(hjkhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjkhhh[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMubj)}(h h]h }(hjkhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjkhhhjkhMubh)}(hpwm_apply_might_sleeph]h)}(hpwm_apply_might_sleeph]hpwm_apply_might_sleep}(hjlhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjlubah}(h]h ](jjeh"]h$]h&]j j uh1hhjkhhhjkhMubj)}(h7(struct pwm_device *pwm, const struct pwm_state *state)h](j)}(hstruct pwm_device *pwmh](j)}(hjh]hstruct}(hj lhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjlubj)}(h h]h }(hj-lhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjlubh)}(hhh]h)}(h pwm_deviceh]h pwm_device}(hj>lhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj;lubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetj@lmodnameN classnameNjj )}j]j)}jjlsbc.pwm_apply_might_sleepasbuh1hhjlubj)}(h h]h }(hj^lhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjlubj%)}(hj(h]h*}(hjllhhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hjlubh)}(hpwmh]hpwm}(hjylhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjlubeh}(h]h ]h"]h$]h&]noemphj j uh1jhjlubj)}(hconst struct pwm_state *stateh](j)}(hjh]hconst}(hjlhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjlubj)}(h h]h }(hjlhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjlubj)}(hjh]hstruct}(hjlhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjlubj)}(h h]h }(hjlhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjlubh)}(hhh]h)}(h pwm_stateh]h pwm_state}(hjlhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjlubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetjlmodnameN classnameNjj )}j]jZlc.pwm_apply_might_sleepasbuh1hhjlubj)}(h h]h }(hjlhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjlubj%)}(hj(h]h*}(hjlhhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hjlubh)}(hstateh]hstate}(hjmhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjlubeh}(h]h ]h"]h$]h&]noemphj j uh1jhjlubeh}(h]h ]h"]h$]h&]j j uh1jhjkhhhjkhMubeh}(h]h ]h"]h$]h&]j j juh1hjjhjkhhhjkhMubah}(h]jkah ](jjeh"]h$]h&]jj )j!huh1hhjkhMhjkhhubj#)}(hhh]j<)}(hNatomically apply a new state to a PWM device Cannot be used in atomic context.h]hNatomically apply a new state to a PWM device Cannot be used in atomic context.}(hj.mhhhNhNubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMhj+mhhubah}(h]h ]h"]h$]h&]uh1j"hjkhhhjkhMubeh}(h]h ](j0functioneh"]h$]h&]j5j0j6jFmj7jFmj8j9j:uh1hhhhj ?hNhNubjs)}(h**Parameters** ``struct pwm_device *pwm`` PWM device ``const struct pwm_state *state`` new state to apply **Return** 0 on success, or a negative errno **Context** May sleep.h](j<)}(h**Parameters**h]j})}(hjPmh]h Parameters}(hjRmhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjNmubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMhjJmubj)}(hhh](j)}(h&``struct pwm_device *pwm`` PWM device h](j)}(h``struct pwm_device *pwm``h]jB)}(hjomh]hstruct pwm_device *pwm}(hjqmhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhjmmubah}(h]h ]h"]h$]h&]uh1jh[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMhjimubj)}(hhh]j<)}(h PWM deviceh]h PWM device}(hjmhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hjmhMhjmubah}(h]h ]h"]h$]h&]uh1jhjimubeh}(h]h ]h"]h$]h&]uh1jhjmhMhjfmubj)}(h5``const struct pwm_state *state`` new state to apply h](j)}(h!``const struct pwm_state *state``h]jB)}(hjmh]hconst struct pwm_state *state}(hjmhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhjmubah}(h]h ]h"]h$]h&]uh1jh[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMhjmubj)}(hhh]j<)}(hnew state to applyh]hnew state to apply}(hjmhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hjmhMhjmubah}(h]h ]h"]h$]h&]uh1jhjmubeh}(h]h ]h"]h$]h&]uh1jhjmhMhjfmubeh}(h]h ]h"]h$]h&]uh1jhjJmubj<)}(h **Return**h]j})}(hjmh]hReturn}(hjmhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjmubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMhjJmubj<)}(h!0 on success, or a negative errnoh]h!0 on success, or a negative errno}(hjmhhhNhNubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMhjJmubj<)}(h **Context**h]j})}(hj nh]hContext}(hj nhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjnubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMhjJmubj<)}(h May sleep.h]h May sleep.}(hj nhhhNhNubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMhjJmubeh}(h]h ] kernelindentah"]h$]h&]uh1jrhj ?hhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](h،pwm_apply_atomic (C function)c.pwm_apply_atomichNtauh1hhj ?hhhNhNubh)}(hhh](h)}(hLint pwm_apply_atomic (struct pwm_device *pwm, const struct pwm_state *state)h]h)}(hKint pwm_apply_atomic(struct pwm_device *pwm, const struct pwm_state *state)h](j)}(hinth]hint}(hjOnhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjKnhhh[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMubj)}(h h]h }(hj^nhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjKnhhhj]nhMubh)}(hpwm_apply_atomich]h)}(hpwm_apply_atomich]hpwm_apply_atomic}(hjpnhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjlnubah}(h]h ](jjeh"]h$]h&]j j uh1hhjKnhhhj]nhMubj)}(h7(struct pwm_device *pwm, const struct pwm_state *state)h](j)}(hstruct pwm_device *pwmh](j)}(hjh]hstruct}(hjnhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjnubj)}(h h]h }(hjnhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjnubh)}(hhh]h)}(h pwm_deviceh]h pwm_device}(hjnhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjnubah}(h]h ]h"]h$]h&] refdomainUj0reftypej reftargetjnmodnameN classnameNjj )}j]j)}jjrnsbc.pwm_apply_atomicasbuh1hhjnubj)}(h h]h }(hjnhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjnubj%)}(hj(h]h*}(hjnhhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hjnubh)}(hpwmh]hpwm}(hjnhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjnubeh}(h]h ]h"]h$]h&]noemphj j uh1jhjnubj)}(hconst struct pwm_state *stateh](j)}(hjh]hconst}(hjnhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjnubj)}(h h]h }(hj ohhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjnubj)}(hjh]hstruct}(hjohhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjnubj)}(h h]h }(hj&ohhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjnubh)}(hhh]h)}(h pwm_stateh]h pwm_state}(hj7ohhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj4oubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetj9omodnameN classnameNjj )}j]jnc.pwm_apply_atomicasbuh1hhjnubj)}(h h]h }(hjUohhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjnubj%)}(hj(h]h*}(hjcohhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hjnubh)}(hstateh]hstate}(hjpohhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjnubeh}(h]h ]h"]h$]h&]noemphj j uh1jhjnubeh}(h]h ]h"]h$]h&]j j uh1jhjKnhhhj]nhMubeh}(h]h ]h"]h$]h&]j j juh1hjjhjGnhhhj]nhMubah}(h]jBnah ](jjeh"]h$]h&]jj )j!huh1hhj]nhMhjDnhhubj#)}(hhh]j<)}(h~apply a new state to a PWM device from atomic context Not all PWM devices support this function, check with pwm_might_sleep().h]h~apply a new state to a PWM device from atomic context Not all PWM devices support this function, check with pwm_might_sleep().}(hjohhhNhNubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMhjohhubah}(h]h ]h"]h$]h&]uh1j"hjDnhhhj]nhMubeh}(h]h ](j0functioneh"]h$]h&]j5j0j6joj7joj8j9j:uh1hhhhj ?hNhNubjs)}(h**Parameters** ``struct pwm_device *pwm`` PWM device ``const struct pwm_state *state`` new state to apply **Return** 0 on success, or a negative errno **Context** Anyh](j<)}(h**Parameters**h]j})}(hjoh]h Parameters}(hjohhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjoubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMhjoubj)}(hhh](j)}(h&``struct pwm_device *pwm`` PWM device h](j)}(h``struct pwm_device *pwm``h]jB)}(hjoh]hstruct pwm_device *pwm}(hjohhhNhNubah}(h]h ]h"]h$]h&]uh1jAhjoubah}(h]h ]h"]h$]h&]uh1jh[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMhjoubj)}(hhh]j<)}(h PWM deviceh]h PWM device}(hjohhhNhNubah}(h]h ]h"]h$]h&]uh1j;hjohMhjoubah}(h]h ]h"]h$]h&]uh1jhjoubeh}(h]h ]h"]h$]h&]uh1jhjohMhjoubj)}(h5``const struct pwm_state *state`` new state to apply h](j)}(h!``const struct pwm_state *state``h]jB)}(hjph]hconst struct pwm_state *state}(hjphhhNhNubah}(h]h ]h"]h$]h&]uh1jAhjpubah}(h]h ]h"]h$]h&]uh1jh[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMhjpubj)}(hhh]j<)}(hnew state to applyh]hnew state to apply}(hj-phhhNhNubah}(h]h ]h"]h$]h&]uh1j;hj)phMhj*pubah}(h]h ]h"]h$]h&]uh1jhjpubeh}(h]h ]h"]h$]h&]uh1jhj)phMhjoubeh}(h]h ]h"]h$]h&]uh1jhjoubj<)}(h **Return**h]j})}(hjOph]hReturn}(hjQphhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjMpubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMhjoubj<)}(h!0 on success, or a negative errnoh]h!0 on success, or a negative errno}(hjephhhNhNubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMhjoubj<)}(h **Context**h]j})}(hjvph]hContext}(hjxphhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjtpubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMhjoubj<)}(hAnyh]hAny}(hjphhhNhNubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMhjoubeh}(h]h ] kernelindentah"]h$]h&]uh1jrhj ?hhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](h،pwm_get_state_hw (C function)c.pwm_get_state_hwhNtauh1hhj ?hhhNhNubh)}(hhh](h)}(hFint pwm_get_state_hw (struct pwm_device *pwm, struct pwm_state *state)h]h)}(hEint pwm_get_state_hw(struct pwm_device *pwm, struct pwm_state *state)h](j)}(hinth]hint}(hjphhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjphhh[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMubj)}(h h]h }(hjphhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjphhhjphMubh)}(hpwm_get_state_hwh]h)}(hpwm_get_state_hwh]hpwm_get_state_hw}(hjphhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjpubah}(h]h ](jjeh"]h$]h&]j j uh1hhjphhhjphMubj)}(h1(struct pwm_device *pwm, struct pwm_state *state)h](j)}(hstruct pwm_device *pwmh](j)}(hjh]hstruct}(hjphhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjpubj)}(h h]h }(hjqhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjpubh)}(hhh]h)}(h pwm_deviceh]h pwm_device}(hjqhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjqubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetjqmodnameN classnameNjj )}j]j)}jjpsbc.pwm_get_state_hwasbuh1hhjpubj)}(h h]h }(hj6qhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjpubj%)}(hj(h]h*}(hjDqhhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hjpubh)}(hpwmh]hpwm}(hjQqhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjpubeh}(h]h ]h"]h$]h&]noemphj j uh1jhjpubj)}(hstruct pwm_state *stateh](j)}(hjh]hstruct}(hjjqhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjfqubj)}(h h]h }(hjwqhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjfqubh)}(hhh]h)}(h pwm_stateh]h pwm_state}(hjqhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjqubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetjqmodnameN classnameNjj )}j]j2qc.pwm_get_state_hwasbuh1hhjfqubj)}(h h]h }(hjqhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjfqubj%)}(hj(h]h*}(hjqhhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hjfqubh)}(hstateh]hstate}(hjqhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjfqubeh}(h]h ]h"]h$]h&]noemphj j uh1jhjpubeh}(h]h ]h"]h$]h&]j j uh1jhjphhhjphMubeh}(h]h ]h"]h$]h&]j j juh1hjjhjphhhjphMubah}(h]jpah ](jjeh"]h$]h&]jj )j!huh1hhjphMhjphhubj#)}(hhh]j<)}(h'get the current PWM state from hardwareh]h'get the current PWM state from hardware}(hjqhhhNhNubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMhjqhhubah}(h]h ]h"]h$]h&]uh1j"hjphhhjphMubeh}(h]h ](j0functioneh"]h$]h&]j5j0j6jrj7jrj8j9j:uh1hhhhj ?hNhNubjs)}(hXR**Parameters** ``struct pwm_device *pwm`` PWM device ``struct pwm_state *state`` state to fill with the current PWM state **Description** Similar to pwm_get_state() but reads the current PWM state from hardware instead of the requested state. **Return** 0 on success or a negative error code on failure. **Context** May sleep.h](j<)}(h**Parameters**h]j})}(hj rh]h Parameters}(hjrhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj rubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMhjrubj)}(hhh](j)}(h&``struct pwm_device *pwm`` PWM device h](j)}(h``struct pwm_device *pwm``h]jB)}(hj,rh]hstruct pwm_device *pwm}(hj.rhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhj*rubah}(h]h ]h"]h$]h&]uh1jh[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMhj&rubj)}(hhh]j<)}(h PWM deviceh]h PWM device}(hjErhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hjArhMhjBrubah}(h]h ]h"]h$]h&]uh1jhj&rubeh}(h]h ]h"]h$]h&]uh1jhjArhMhj#rubj)}(hE``struct pwm_state *state`` state to fill with the current PWM state h](j)}(h``struct pwm_state *state``h]jB)}(hjerh]hstruct pwm_state *state}(hjgrhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhjcrubah}(h]h ]h"]h$]h&]uh1jh[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMhj_rubj)}(hhh]j<)}(h(state to fill with the current PWM stateh]h(state to fill with the current PWM state}(hj~rhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hjzrhMhj{rubah}(h]h ]h"]h$]h&]uh1jhj_rubeh}(h]h ]h"]h$]h&]uh1jhjzrhMhj#rubeh}(h]h ]h"]h$]h&]uh1jhjrubj<)}(h**Description**h]j})}(hjrh]h Description}(hjrhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjrubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMhjrubj<)}(hhSimilar to pwm_get_state() but reads the current PWM state from hardware instead of the requested state.h]hhSimilar to pwm_get_state() but reads the current PWM state from hardware instead of the requested state.}(hjrhhhNhNubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMhjrubj<)}(h **Return**h]j})}(hjrh]hReturn}(hjrhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjrubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chM hjrubj<)}(h10 on success or a negative error code on failure.h]h10 on success or a negative error code on failure.}(hjrhhhNhNubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chM!hjrubj<)}(h **Context**h]j})}(hjrh]hContext}(hjrhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjrubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chM#hjrubj<)}(h May sleep.h]h May sleep.}(hjshhhNhNubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chM"hjrubeh}(h]h ] kernelindentah"]h$]h&]uh1jrhj ?hhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](h،pwm_adjust_config (C function)c.pwm_adjust_confighNtauh1hhj ?hhhNhNubh)}(hhh](h)}(h.int pwm_adjust_config (struct pwm_device *pwm)h]h)}(h-int pwm_adjust_config(struct pwm_device *pwm)h](j)}(hinth]hint}(hj3shhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj/shhh[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMKubj)}(h h]h }(hjBshhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj/shhhjAshMKubh)}(hpwm_adjust_configh]h)}(hpwm_adjust_configh]hpwm_adjust_config}(hjTshhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjPsubah}(h]h ](jjeh"]h$]h&]j j uh1hhj/shhhjAshMKubj)}(h(struct pwm_device *pwm)h]j)}(hstruct pwm_device *pwmh](j)}(hjh]hstruct}(hjpshhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjlsubj)}(h h]h }(hj}shhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjlsubh)}(hhh]h)}(h pwm_deviceh]h pwm_device}(hjshhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjsubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetjsmodnameN classnameNjj )}j]j)}jjVssbc.pwm_adjust_configasbuh1hhjlsubj)}(h h]h }(hjshhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjlsubj%)}(hj(h]h*}(hjshhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hjlsubh)}(hpwmh]hpwm}(hjshhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjlsubeh}(h]h ]h"]h$]h&]noemphj j uh1jhjhsubah}(h]h ]h"]h$]h&]j j uh1jhj/shhhjAshMKubeh}(h]h ]h"]h$]h&]j j juh1hjjhj+shhhjAshMKubah}(h]j&sah ](jjeh"]h$]h&]jj )j!huh1hhjAshMKhj(shhubj#)}(hhh]j<)}(h2adjust the current PWM config to the PWM argumentsh]h2adjust the current PWM config to the PWM arguments}(hjshhhNhNubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMKhjshhubah}(h]h ]h"]h$]h&]uh1j"hj(shhhjAshMKubeh}(h]h ](j0functioneh"]h$]h&]j5j0j6j tj7j tj8j9j:uh1hhhhj ?hNhNubjs)}(hXT**Parameters** ``struct pwm_device *pwm`` PWM device **Description** This function will adjust the PWM config to the PWM arguments provided by the DT or PWM lookup table. This is particularly useful to adapt the bootloader config to the Linux one. **Return** 0 on success or a negative error code on failure. **Context** May sleep.h](j<)}(h**Parameters**h]j})}(hjth]h Parameters}(hjthhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjtubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMOhjtubj)}(hhh]j)}(h&``struct pwm_device *pwm`` PWM device h](j)}(h``struct pwm_device *pwm``h]jB)}(hj4th]hstruct pwm_device *pwm}(hj6thhhNhNubah}(h]h ]h"]h$]h&]uh1jAhj2tubah}(h]h ]h"]h$]h&]uh1jh[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMLhj.tubj)}(hhh]j<)}(h PWM deviceh]h PWM device}(hjMthhhNhNubah}(h]h ]h"]h$]h&]uh1j;hjIthMLhjJtubah}(h]h ]h"]h$]h&]uh1jhj.tubeh}(h]h ]h"]h$]h&]uh1jhjIthMLhj+tubah}(h]h ]h"]h$]h&]uh1jhjtubj<)}(h**Description**h]j})}(hjoth]h Description}(hjqthhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjmtubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMNhjtubj<)}(hThis function will adjust the PWM config to the PWM arguments provided by the DT or PWM lookup table. This is particularly useful to adapt the bootloader config to the Linux one.h]hThis function will adjust the PWM config to the PWM arguments provided by the DT or PWM lookup table. This is particularly useful to adapt the bootloader config to the Linux one.}(hjthhhNhNubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMMhjtubj<)}(h **Return**h]j})}(hjth]hReturn}(hjthhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjtubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMQhjtubj<)}(h10 on success or a negative error code on failure.h]h10 on success or a negative error code on failure.}(hjthhhNhNubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMRhjtubj<)}(h **Context**h]j})}(hjth]hContext}(hjthhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjtubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMThjtubj<)}(h May sleep.h]h May sleep.}(hjthhhNhNubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMShjtubeh}(h]h ] kernelindentah"]h$]h&]uh1jrhj ?hhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](h،pwm_get (C function) c.pwm_gethNtauh1hhj ?hhhNhNubh)}(hhh](h)}(hDstruct pwm_device * pwm_get (struct device *dev, const char *con_id)h]h)}(hBstruct pwm_device *pwm_get(struct device *dev, const char *con_id)h](j)}(hjh]hstruct}(hjuhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjthhh[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMjubj)}(h h]h }(hjuhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjthhhjuhMjubh)}(hhh]h)}(h pwm_deviceh]h pwm_device}(hj!uhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjuubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetj#umodnameN classnameNjj )}j]j)}jpwm_getsb c.pwm_getasbuh1hhjthhhjuhMjubj)}(h h]h }(hjBuhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjthhhjuhMjubj%)}(hj(h]h*}(hjPuhhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hjthhhjuhMjubh)}(hpwm_geth]h)}(hj?uh]hpwm_get}(hjauhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj]uubah}(h]h ](jjeh"]h$]h&]j j uh1hhjthhhjuhMjubj)}(h((struct device *dev, const char *con_id)h](j)}(hstruct device *devh](j)}(hjh]hstruct}(hj|uhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjxuubj)}(h h]h }(hjuhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjxuubh)}(hhh]h)}(hdeviceh]hdevice}(hjuhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjuubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetjumodnameN classnameNjj )}j]j=u c.pwm_getasbuh1hhjxuubj)}(h h]h }(hjuhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjxuubj%)}(hj(h]h*}(hjuhhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hjxuubh)}(hdevh]hdev}(hjuhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjxuubeh}(h]h ]h"]h$]h&]noemphj j uh1jhjtuubj)}(hconst char *con_idh](j)}(hjh]hconst}(hjuhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjuubj)}(h h]h }(hjuhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjuubj)}(hcharh]hchar}(hjvhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjuubj)}(h h]h }(hjvhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjuubj%)}(hj(h]h*}(hj#vhhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hjuubh)}(hcon_idh]hcon_id}(hj0vhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjuubeh}(h]h ]h"]h$]h&]noemphj j uh1jhjtuubeh}(h]h ]h"]h$]h&]j j uh1jhjthhhjuhMjubeh}(h]h ]h"]h$]h&]j j juh1hjjhjthhhjuhMjubah}(h]jtah ](jjeh"]h$]h&]jj )j!huh1hhjuhMjhjthhubj#)}(hhh]j<)}(h look up and request a PWM deviceh]h look up and request a PWM device}(hjZvhhhNhNubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMjhjWvhhubah}(h]h ]h"]h$]h&]uh1j"hjthhhjuhMjubeh}(h]h ](j0functioneh"]h$]h&]j5j0j6jrvj7jrvj8j9j:uh1hhhhj ?hNhNubjs)}(hX**Parameters** ``struct device *dev`` device for PWM consumer ``const char *con_id`` consumer name **Description** Lookup is first attempted using DT. If the device was not instantiated from a device tree, a PWM chip and a relative index is looked up via a table supplied by board setup code (see pwm_add_table()). Once a PWM chip has been found the specified PWM device will be requested and is ready to be used. **Return** A pointer to the requested PWM device or an ERR_PTR()-encoded error code on failure.h](j<)}(h**Parameters**h]j})}(hj|vh]h Parameters}(hj~vhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjzvubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMnhjvvubj)}(hhh](j)}(h/``struct device *dev`` device for PWM consumer h](j)}(h``struct device *dev``h]jB)}(hjvh]hstruct device *dev}(hjvhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhjvubah}(h]h ]h"]h$]h&]uh1jh[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMkhjvubj)}(hhh]j<)}(hdevice for PWM consumerh]hdevice for PWM consumer}(hjvhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hjvhMkhjvubah}(h]h ]h"]h$]h&]uh1jhjvubeh}(h]h ]h"]h$]h&]uh1jhjvhMkhjvubj)}(h%``const char *con_id`` consumer name h](j)}(h``const char *con_id``h]jB)}(hjvh]hconst char *con_id}(hjvhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhjvubah}(h]h ]h"]h$]h&]uh1jh[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMlhjvubj)}(hhh]j<)}(h consumer nameh]h consumer name}(hjvhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hjvhMlhjvubah}(h]h ]h"]h$]h&]uh1jhjvubeh}(h]h ]h"]h$]h&]uh1jhjvhMlhjvubeh}(h]h ]h"]h$]h&]uh1jhjvvubj<)}(h**Description**h]j})}(hjwh]h Description}(hjwhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj wubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMnhjvvubj<)}(hLookup is first attempted using DT. If the device was not instantiated from a device tree, a PWM chip and a relative index is looked up via a table supplied by board setup code (see pwm_add_table()).h]hLookup is first attempted using DT. If the device was not instantiated from a device tree, a PWM chip and a relative index is looked up via a table supplied by board setup code (see pwm_add_table()).}(hj%whhhNhNubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMmhjvvubj<)}(hbOnce a PWM chip has been found the specified PWM device will be requested and is ready to be used.h]hbOnce a PWM chip has been found the specified PWM device will be requested and is ready to be used.}(hj4whhhNhNubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMqhjvvubj<)}(h **Return**h]j})}(hjEwh]hReturn}(hjGwhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjCwubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMthjvvubj<)}(hTA pointer to the requested PWM device or an ERR_PTR()-encoded error code on failure.h]hTA pointer to the requested PWM device or an ERR_PTR()-encoded error code on failure.}(hj[whhhNhNubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMuhjvvubeh}(h]h ] kernelindentah"]h$]h&]uh1jrhj ?hhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](h،pwm_put (C function) c.pwm_puthNtauh1hhj ?hhhNhNubh)}(hhh](h)}(h%void pwm_put (struct pwm_device *pwm)h]h)}(h$void pwm_put(struct pwm_device *pwm)h](j)}(hvoidh]hvoid}(hjwhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjwhhh[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMubj)}(h h]h }(hjwhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjwhhhjwhMubh)}(hpwm_puth]h)}(hpwm_puth]hpwm_put}(hjwhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjwubah}(h]h ](jjeh"]h$]h&]j j uh1hhjwhhhjwhMubj)}(h(struct pwm_device *pwm)h]j)}(hstruct pwm_device *pwmh](j)}(hjh]hstruct}(hjwhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjwubj)}(h h]h }(hjwhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjwubh)}(hhh]h)}(h pwm_deviceh]h pwm_device}(hjwhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjwubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetjwmodnameN classnameNjj )}j]j)}jjwsb c.pwm_putasbuh1hhjwubj)}(h h]h }(hjxhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjwubj%)}(hj(h]h*}(hjxhhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hjwubh)}(hpwmh]hpwm}(hj xhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjwubeh}(h]h ]h"]h$]h&]noemphj j uh1jhjwubah}(h]h ]h"]h$]h&]j j uh1jhjwhhhjwhMubeh}(h]h ]h"]h$]h&]j j juh1hjjhjwhhhjwhMubah}(h]j}wah ](jjeh"]h$]h&]jj )j!huh1hhjwhMhjwhhubj#)}(hhh]j<)}(hrelease a PWM deviceh]hrelease a PWM device}(hjJxhhhNhNubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMhjGxhhubah}(h]h ]h"]h$]h&]uh1j"hjwhhhjwhMubeh}(h]h ](j0functioneh"]h$]h&]j5j0j6jbxj7jbxj8j9j:uh1hhhhj ?hNhNubjs)}(h7**Parameters** ``struct pwm_device *pwm`` PWM deviceh](j<)}(h**Parameters**h]j})}(hjlxh]h Parameters}(hjnxhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjjxubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMhjfxubj)}(hhh]j)}(h%``struct pwm_device *pwm`` PWM deviceh](j)}(h``struct pwm_device *pwm``h]jB)}(hjxh]hstruct pwm_device *pwm}(hjxhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhjxubah}(h]h ]h"]h$]h&]uh1jh[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMhjxubj)}(hhh]j<)}(h PWM deviceh]h PWM device}(hjxhhhNhNubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMhjxubah}(h]h ]h"]h$]h&]uh1jhjxubeh}(h]h ]h"]h$]h&]uh1jhjxhMhjxubah}(h]h ]h"]h$]h&]uh1jhjfxubeh}(h]h ] kernelindentah"]h$]h&]uh1jrhj ?hhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](h،devm_pwm_get (C function)c.devm_pwm_gethNtauh1hhj ?hhhNhNubh)}(hhh](h)}(hIstruct pwm_device * devm_pwm_get (struct device *dev, const char *con_id)h]h)}(hGstruct pwm_device *devm_pwm_get(struct device *dev, const char *con_id)h](j)}(hjh]hstruct}(hjxhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjxhhh[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMubj)}(h h]h }(hjxhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjxhhhjxhMubh)}(hhh]h)}(h pwm_deviceh]h pwm_device}(hjyhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjyubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetjymodnameN classnameNjj )}j]j)}j devm_pwm_getsbc.devm_pwm_getasbuh1hhjxhhhjxhMubj)}(h h]h }(hj%yhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjxhhhjxhMubj%)}(hj(h]h*}(hj3yhhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hjxhhhjxhMubh)}(h devm_pwm_geth]h)}(hj"yh]h devm_pwm_get}(hjDyhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj@yubah}(h]h ](jjeh"]h$]h&]j j uh1hhjxhhhjxhMubj)}(h((struct device *dev, const char *con_id)h](j)}(hstruct device *devh](j)}(hjh]hstruct}(hj_yhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj[yubj)}(h h]h }(hjlyhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj[yubh)}(hhh]h)}(hdeviceh]hdevice}(hj}yhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjzyubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetjymodnameN classnameNjj )}j]j yc.devm_pwm_getasbuh1hhj[yubj)}(h h]h }(hjyhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj[yubj%)}(hj(h]h*}(hjyhhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hj[yubh)}(hdevh]hdev}(hjyhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj[yubeh}(h]h ]h"]h$]h&]noemphj j uh1jhjWyubj)}(hconst char *con_idh](j)}(hjh]hconst}(hjyhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjyubj)}(h h]h }(hjyhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjyubj)}(hcharh]hchar}(hjyhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjyubj)}(h h]h }(hjyhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjyubj%)}(hj(h]h*}(hjzhhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hjyubh)}(hcon_idh]hcon_id}(hjzhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjyubeh}(h]h ]h"]h$]h&]noemphj j uh1jhjWyubeh}(h]h ]h"]h$]h&]j j uh1jhjxhhhjxhMubeh}(h]h ]h"]h$]h&]j j juh1hjjhjxhhhjxhMubah}(h]jxah ](jjeh"]h$]h&]jj )j!huh1hhjxhMhjxhhubj#)}(hhh]j<)}(hresource managed pwm_get()h]hresource managed pwm_get()}(hj=zhhhNhNubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMhj:zhhubah}(h]h ]h"]h$]h&]uh1j"hjxhhhjxhMubeh}(h]h ](j0functioneh"]h$]h&]j5j0j6jUzj7jUzj8j9j:uh1hhhhj ?hNhNubjs)}(hXO**Parameters** ``struct device *dev`` device for PWM consumer ``const char *con_id`` consumer name **Description** This function performs like pwm_get() but the acquired PWM device will automatically be released on driver detach. **Return** A pointer to the requested PWM device or an ERR_PTR()-encoded error code on failure.h](j<)}(h**Parameters**h]j})}(hj_zh]h Parameters}(hjazhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj]zubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMhjYzubj)}(hhh](j)}(h/``struct device *dev`` device for PWM consumer h](j)}(h``struct device *dev``h]jB)}(hj~zh]hstruct device *dev}(hjzhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhj|zubah}(h]h ]h"]h$]h&]uh1jh[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMhjxzubj)}(hhh]j<)}(hdevice for PWM consumerh]hdevice for PWM consumer}(hjzhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hjzhMhjzubah}(h]h ]h"]h$]h&]uh1jhjxzubeh}(h]h ]h"]h$]h&]uh1jhjzhMhjuzubj)}(h%``const char *con_id`` consumer name h](j)}(h``const char *con_id``h]jB)}(hjzh]hconst char *con_id}(hjzhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhjzubah}(h]h ]h"]h$]h&]uh1jh[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMhjzubj)}(hhh]j<)}(h consumer nameh]h consumer name}(hjzhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hjzhMhjzubah}(h]h ]h"]h$]h&]uh1jhjzubeh}(h]h ]h"]h$]h&]uh1jhjzhMhjuzubeh}(h]h ]h"]h$]h&]uh1jhjYzubj<)}(h**Description**h]j})}(hjzh]h Description}(hjzhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjzubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMhjYzubj<)}(hrThis function performs like pwm_get() but the acquired PWM device will automatically be released on driver detach.h]hrThis function performs like pwm_get() but the acquired PWM device will automatically be released on driver detach.}(hj{hhhNhNubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMhjYzubj<)}(h **Return**h]j})}(hj{h]hReturn}(hj{hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj{ubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMhjYzubj<)}(hTA pointer to the requested PWM device or an ERR_PTR()-encoded error code on failure.h]hTA pointer to the requested PWM device or an ERR_PTR()-encoded error code on failure.}(hj/{hhhNhNubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chMhjYzubeh}(h]h ] kernelindentah"]h$]h&]uh1jrhj ?hhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](h، devm_fwnode_pwm_get (C function)c.devm_fwnode_pwm_gethNtauh1hhj ?hhhNhNubh)}(hhh](h)}(hnstruct pwm_device * devm_fwnode_pwm_get (struct device *dev, struct fwnode_handle *fwnode, const char *con_id)h]h)}(hlstruct pwm_device *devm_fwnode_pwm_get(struct device *dev, struct fwnode_handle *fwnode, const char *con_id)h](j)}(hjh]hstruct}(hj^{hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjZ{hhh[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chM-ubj)}(h h]h }(hjl{hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjZ{hhhjk{hM-ubh)}(hhh]h)}(h pwm_deviceh]h pwm_device}(hj}{hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjz{ubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetj{modnameN classnameNjj )}j]j)}jdevm_fwnode_pwm_getsbc.devm_fwnode_pwm_getasbuh1hhjZ{hhhjk{hM-ubj)}(h h]h }(hj{hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjZ{hhhjk{hM-ubj%)}(hj(h]h*}(hj{hhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hjZ{hhhjk{hM-ubh)}(hdevm_fwnode_pwm_geth]h)}(hj{h]hdevm_fwnode_pwm_get}(hj{hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj{ubah}(h]h ](jjeh"]h$]h&]j j uh1hhjZ{hhhjk{hM-ubj)}(hF(struct device *dev, struct fwnode_handle *fwnode, const char *con_id)h](j)}(hstruct device *devh](j)}(hjh]hstruct}(hj{hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj{ubj)}(h h]h }(hj{hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj{ubh)}(hhh]h)}(hdeviceh]hdevice}(hj{hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj{ubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetj{modnameN classnameNjj )}j]j{c.devm_fwnode_pwm_getasbuh1hhj{ubj)}(h h]h }(hj|hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj{ubj%)}(hj(h]h*}(hj"|hhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hj{ubh)}(hdevh]hdev}(hj/|hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj{ubeh}(h]h ]h"]h$]h&]noemphj j uh1jhj{ubj)}(hstruct fwnode_handle *fwnodeh](j)}(hjh]hstruct}(hjH|hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjD|ubj)}(h h]h }(hjU|hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjD|ubh)}(hhh]h)}(h fwnode_handleh]h fwnode_handle}(hjf|hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjc|ubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetjh|modnameN classnameNjj )}j]j{c.devm_fwnode_pwm_getasbuh1hhjD|ubj)}(h h]h }(hj|hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjD|ubj%)}(hj(h]h*}(hj|hhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hjD|ubh)}(hfwnodeh]hfwnode}(hj|hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjD|ubeh}(h]h ]h"]h$]h&]noemphj j uh1jhj{ubj)}(hconst char *con_idh](j)}(hjh]hconst}(hj|hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj|ubj)}(h h]h }(hj|hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj|ubj)}(hcharh]hchar}(hj|hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj|ubj)}(h h]h }(hj|hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj|ubj%)}(hj(h]h*}(hj|hhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hj|ubh)}(hcon_idh]hcon_id}(hj|hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj|ubeh}(h]h ]h"]h$]h&]noemphj j uh1jhj{ubeh}(h]h ]h"]h$]h&]j j uh1jhjZ{hhhjk{hM-ubeh}(h]h ]h"]h$]h&]j j juh1hjjhjV{hhhjk{hM-ubah}(h]jQ{ah ](jjeh"]h$]h&]jj )j!huh1hhjk{hM-hjS{hhubj#)}(hhh]j<)}(h1request a resource managed PWM from firmware nodeh]h1request a resource managed PWM from firmware node}(hj&}hhhNhNubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chM-hj#}hhubah}(h]h ]h"]h$]h&]uh1j"hjS{hhhjk{hM-ubeh}(h]h ](j0functioneh"]h$]h&]j5j0j6j>}j7j>}j8j9j:uh1hhhhj ?hNhNubjs)}(hX**Parameters** ``struct device *dev`` device for PWM consumer ``struct fwnode_handle *fwnode`` firmware node to get the PWM from ``const char *con_id`` consumer name **Description** Returns the PWM device parsed from the firmware node. See of_pwm_get() and acpi_pwm_get() for a detailed description. **Return** A pointer to the requested PWM device or an ERR_PTR()-encoded error code on failure.h](j<)}(h**Parameters**h]j})}(hjH}h]h Parameters}(hjJ}hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjF}ubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chM1hjB}ubj)}(hhh](j)}(h/``struct device *dev`` device for PWM consumer h](j)}(h``struct device *dev``h]jB)}(hjg}h]hstruct device *dev}(hji}hhhNhNubah}(h]h ]h"]h$]h&]uh1jAhje}ubah}(h]h ]h"]h$]h&]uh1jh[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chM.hja}ubj)}(hhh]j<)}(hdevice for PWM consumerh]hdevice for PWM consumer}(hj}hhhNhNubah}(h]h ]h"]h$]h&]uh1j;hj|}hM.hj}}ubah}(h]h ]h"]h$]h&]uh1jhja}ubeh}(h]h ]h"]h$]h&]uh1jhj|}hM.hj^}ubj)}(hC``struct fwnode_handle *fwnode`` firmware node to get the PWM from h](j)}(h ``struct fwnode_handle *fwnode``h]jB)}(hj}h]hstruct fwnode_handle *fwnode}(hj}hhhNhNubah}(h]h ]h"]h$]h&]uh1jAhj}ubah}(h]h ]h"]h$]h&]uh1jh[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chM/hj}ubj)}(hhh]j<)}(h!firmware node to get the PWM fromh]h!firmware node to get the PWM from}(hj}hhhNhNubah}(h]h ]h"]h$]h&]uh1j;hj}hM/hj}ubah}(h]h ]h"]h$]h&]uh1jhj}ubeh}(h]h ]h"]h$]h&]uh1jhj}hM/hj^}ubj)}(h%``const char *con_id`` consumer name h](j)}(h``const char *con_id``h]jB)}(hj}h]hconst char *con_id}(hj}hhhNhNubah}(h]h ]h"]h$]h&]uh1jAhj}ubah}(h]h ]h"]h$]h&]uh1jh[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chM0hj}ubj)}(hhh]j<)}(h consumer nameh]h consumer name}(hj}hhhNhNubah}(h]h ]h"]h$]h&]uh1j;hj}hM0hj}ubah}(h]h ]h"]h$]h&]uh1jhj}ubeh}(h]h ]h"]h$]h&]uh1jhj}hM0hj^}ubeh}(h]h ]h"]h$]h&]uh1jhjB}ubj<)}(h**Description**h]j})}(hj~h]h Description}(hj~hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj~ubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chM2hjB}ubj<)}(huReturns the PWM device parsed from the firmware node. See of_pwm_get() and acpi_pwm_get() for a detailed description.h]huReturns the PWM device parsed from the firmware node. See of_pwm_get() and acpi_pwm_get() for a detailed description.}(hj*~hhhNhNubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chM1hjB}ubj<)}(h **Return**h]j})}(hj;~h]hReturn}(hj=~hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj9~ubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chM4hjB}ubj<)}(hTA pointer to the requested PWM device or an ERR_PTR()-encoded error code on failure.h]hTA pointer to the requested PWM device or an ERR_PTR()-encoded error code on failure.}(hjQ~hhhNhNubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chM5hjB}ubeh}(h]h ] kernelindentah"]h$]h&]uh1jrhj ?hhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](h،__pwmchip_add (C function)c.__pwmchip_addhNtauh1hhj ?hhhNhNubh)}(hhh](h)}(h?int __pwmchip_add (struct pwm_chip *chip, struct module *owner)h]h)}(h>int __pwmchip_add(struct pwm_chip *chip, struct module *owner)h](j)}(hinth]hint}(hj~hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj|~hhh[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chM ubj)}(h h]h }(hj~hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj|~hhhj~hM ubh)}(h __pwmchip_addh]h)}(h __pwmchip_addh]h __pwmchip_add}(hj~hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj~ubah}(h]h ](jjeh"]h$]h&]j j uh1hhj|~hhhj~hM ubj)}(h-(struct pwm_chip *chip, struct module *owner)h](j)}(hstruct pwm_chip *chiph](j)}(hjh]hstruct}(hj~hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj~ubj)}(h h]h }(hj~hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj~ubh)}(hhh]h)}(hpwm_chiph]hpwm_chip}(hj~hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj~ubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetj~modnameN classnameNjj )}j]j)}jj~sbc.__pwmchip_addasbuh1hhj~ubj)}(h h]h }(hj~hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj~ubj%)}(hj(h]h*}(hj hhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hj~ubh)}(hchiph]hchip}(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj~ubeh}(h]h ]h"]h$]h&]noemphj j uh1jhj~ubj)}(hstruct module *ownerh](j)}(hjh]hstruct}(hj/hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj+ubj)}(h h]h }(hj<hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj+ubh)}(hhh]h)}(hmoduleh]hmodule}(hjMhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjJubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetjOmodnameN classnameNjj )}j]j~c.__pwmchip_addasbuh1hhj+ubj)}(h h]h }(hjkhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj+ubj%)}(hj(h]h*}(hjyhhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hj+ubh)}(hownerh]howner}(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj+ubeh}(h]h ]h"]h$]h&]noemphj j uh1jhj~ubeh}(h]h ]h"]h$]h&]j j uh1jhj|~hhhj~hM ubeh}(h]h ]h"]h$]h&]j j juh1hjjhjx~hhhj~hM ubah}(h]js~ah ](jjeh"]h$]h&]jj )j!huh1hhj~hM hju~hhubj#)}(hhh]j<)}(hregister a new PWM chiph]hregister a new PWM chip}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chM hjhhubah}(h]h ]h"]h$]h&]uh1j"hju~hhhj~hM ubeh}(h]h ](j0functioneh"]h$]h&]j5j0j6jj7jj8j9j:uh1hhhhj ?hNhNubjs)}(hXH**Parameters** ``struct pwm_chip *chip`` the PWM chip to add ``struct module *owner`` reference to the module providing the chip. **Description** Register a new PWM chip. **owner** is supposed to be THIS_MODULE, use the pwmchip_add wrapper to do this right. **Return** 0 on success or a negative error code on failure.h](j<)}(h**Parameters**h]j})}(hjh]h Parameters}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chM hjubj)}(hhh](j)}(h.``struct pwm_chip *chip`` the PWM chip to add h](j)}(h``struct pwm_chip *chip``h]jB)}(hjh]hstruct pwm_chip *chip}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhjubah}(h]h ]h"]h$]h&]uh1jh[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chM hjubj)}(hhh]j<)}(hthe PWM chip to addh]hthe PWM chip to add}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1j;hjhM hjubah}(h]h ]h"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]uh1jhjhM hjubj)}(hE``struct module *owner`` reference to the module providing the chip. h](j)}(h``struct module *owner``h]jB)}(hj*h]hstruct module *owner}(hj,hhhNhNubah}(h]h ]h"]h$]h&]uh1jAhj(ubah}(h]h ]h"]h$]h&]uh1jh[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chM hj$ubj)}(hhh]j<)}(h+reference to the module providing the chip.h]h+reference to the module providing the chip.}(hjChhhNhNubah}(h]h ]h"]h$]h&]uh1j;hj?hM hj@ubah}(h]h ]h"]h$]h&]uh1jhj$ubeh}(h]h ]h"]h$]h&]uh1jhj?hM hjubeh}(h]h ]h"]h$]h&]uh1jhjubj<)}(h**Description**h]j})}(hjeh]h Description}(hjghhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjcubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chM hjubj<)}(hoRegister a new PWM chip. **owner** is supposed to be THIS_MODULE, use the pwmchip_add wrapper to do this right.h](hRegister a new PWM chip. }(hj{hhhNhNubj})}(h **owner**h]howner}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hj{ubhM is supposed to be THIS_MODULE, use the pwmchip_add wrapper to do this right.}(hj{hhhNhNubeh}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chM hjubj<)}(h **Return**h]j})}(hjh]hReturn}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chM hjubj<)}(h10 on success or a negative error code on failure.h]h10 on success or a negative error code on failure.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chM hjubeh}(h]h ] kernelindentah"]h$]h&]uh1jrhj ?hhhNhNubh)}(hhh]h}(h]h ]h"]h$]h&]entries](h،pwmchip_remove (C function)c.pwmchip_removehNtauh1hhj ?hhhNhNubh)}(hhh](h)}(h+void pwmchip_remove (struct pwm_chip *chip)h]h)}(h*void pwmchip_remove(struct pwm_chip *chip)h](j)}(hvoidh]hvoid}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj߀hhh[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chM ubj)}(h h]h }(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj߀hhhjhM ubh)}(hpwmchip_removeh]h)}(hpwmchip_removeh]hpwmchip_remove}(hjhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubah}(h]h ](jjeh"]h$]h&]j j uh1hhj߀hhhjhM ubj)}(h(struct pwm_chip *chip)h]j)}(hstruct pwm_chip *chiph](j)}(hjh]hstruct}(hj hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hj-hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubh)}(hhh]h)}(hpwm_chiph]hpwm_chip}(hj>hhhNhNubah}(h]h ]hah"]h$]h&]uh1hhj;ubah}(h]h ]h"]h$]h&] refdomainj0reftypej reftargetj@modnameN classnameNjj )}j]j)}jjsbc.pwmchip_removeasbuh1hhjubj)}(h h]h }(hj^hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj%)}(hj(h]h*}(hjlhhhNhNubah}(h]h ]j1ah"]h$]h&]uh1j$hjubh)}(hchiph]hchip}(hjyhhhNhNubah}(h]h ]hah"]h$]h&]uh1hhjubeh}(h]h ]h"]h$]h&]noemphj j uh1jhjubah}(h]h ]h"]h$]h&]j j uh1jhj߀hhhjhM ubeh}(h]h ]h"]h$]h&]j j juh1hjjhjۀhhhjhM ubah}(h]jրah ](jjeh"]h$]h&]jj )j!huh1hhjhM hj؀hhubj#)}(hhh]j<)}(hremove a PWM chiph]hremove a PWM chip}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chM hjhhubah}(h]h ]h"]h$]h&]uh1j"hj؀hhhjhM ubeh}(h]h ](j0functioneh"]h$]h&]j5j0j6jj7jj8j9j:uh1hhhhj ?hNhNubjs)}(hh**Parameters** ``struct pwm_chip *chip`` the PWM chip to remove **Description** Removes a PWM chip.h](j<)}(h**Parameters**h]j})}(hjŁh]h Parameters}(hjǁhhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjÁubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chM hjubj)}(hhh]j)}(h1``struct pwm_chip *chip`` the PWM chip to remove h](j)}(h``struct pwm_chip *chip``h]jB)}(hjh]hstruct pwm_chip *chip}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jAhjubah}(h]h ]h"]h$]h&]uh1jh[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chM hjށubj)}(hhh]j<)}(hthe PWM chip to removeh]hthe PWM chip to remove}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j;hjhM hjubah}(h]h ]h"]h$]h&]uh1jhjށubeh}(h]h ]h"]h$]h&]uh1jhjhM hjہubah}(h]h ]h"]h$]h&]uh1jhjubj<)}(h**Description**h]j})}(hjh]h Description}(hj!hhhNhNubah}(h]h ]h"]h$]h&]uh1j|hjubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chM hjubj<)}(hRemoves a PWM chip.h]hRemoves a PWM chip.}(hj5hhhNhNubah}(h]h ]h"]h$]h&]uh1j;h[/var/lib/git/docbuild/linux/Documentation/driver-api/miscellaneous:47: ./drivers/pwm/core.chM hjubeh}(h]h ] kernelindentah"]h$]h&]uh1jrhj ?hhhNhNubeh}(h]pulse-width-modulation-pwmah ]h"]pulse-width modulation (pwm)ah$]h&]uh1hhhhhhhhKubeh}(h]h ]h"]h$]h&]sourcehuh1hcurrent_sourceN current_lineNsettingsdocutils.frontendValues)}(hN generatorN datestampN source_linkN source_urlN toc_backlinksentryfootnote_backlinksK sectnum_xformKstrip_commentsNstrip_elements_with_classesN strip_classesN report_levelK halt_levelKexit_status_levelKdebugNwarning_streamN tracebackinput_encoding utf-8-siginput_encoding_error_handlerstrictoutput_encodingutf-8output_encoding_error_handlerjverror_encodingutf-8error_encoding_error_handlerbackslashreplace language_codeenrecord_dependenciesNconfigN id_prefixhauto_id_prefixid dump_settingsNdump_internalsNdump_transformsNdump_pseudo_xmlNexpose_internalsNstrict_visitorN_disable_configN_sourcehʌ _destinationN _config_files]7/var/lib/git/docbuild/linux/Documentation/docutils.confafile_insertion_enabled raw_enabledKline_length_limitM'pep_referencesN pep_base_urlhttps://peps.python.org/pep_file_url_templatepep-%04drfc_referencesN rfc_base_url&https://datatracker.ietf.org/doc/html/ tab_widthKtrim_footnote_reference_spacesyntax_highlightlong smart_quotessmartquotes_locales]character_level_inline_markupdoctitle_xform docinfo_xformKsectsubtitle_xform image_loadinglinkembed_stylesheetcloak_email_addressessection_self_linkenvNubreporterNindirect_targets]substitution_defs}substitution_names}refnames}refids}nameids}(j7j7j ?j?jPjMu nametypes}(j7j ?jPuh}(j7hhhjnjsjxj}j"j'jjjjj j j j jjjjj+j0jRjWjjjjjMjRj"j"j#j#jX%j]%j**j/*j+j+j`-je-j(/j-/j0j0j>2jC2j3j3j 6j6j?j7j7j7jV9j[9j:j:j;j;j=j=jMj ?j?j?j@j@jIBjNBjDjDj|FjFjHjHjKjKjNjNjQjQjSjSj#Vj(VjZjZj\j\jp^ju^j_j_jLajQajbjbjejej.hj3hjkjkjBnjGnjpjpj&sj+sjtjtj}wjwjxjxjQ{jV{js~jx~jրjۀu footnote_refs} citation_refs} autofootnotes]autofootnote_refs]symbol_footnotes]symbol_footnote_refs] footnotes] citations]autofootnote_startKsymbol_footnote_startK id_counter collectionsCounter}Rparse_messages]transform_messages] transformerN include_log] decorationNhhub.