Unit Instance
Units API.
See the Weblate's Web API documentation for detailed description of the API.
GET /api/units/229462/?format=api
{ "translation": "https://translate-dev.freebsd.org/api/translations/freebsd-doc/boooks_arch-handbook/zh_CN/?format=api", "source": [ "The poll function is used to simulate the interrupts when the interrupt subsystem is not functioning (for example, when the system has crashed and is creating the system dump). The CAM subsystem sets the proper interrupt level before calling the poll routine. So all it needs to do is to call the interrupt routine (or the other way around, the poll routine may be doing the real action and the interrupt routine would just call the poll routine). Why bother about a separate function then? Due to different calling conventions. The <function>xxx_poll</function> routine gets the struct cam_sim pointer as its argument when the PCI interrupt routine by common convention gets pointer to the struct <varname remap=\"structname\">xxx_softc</varname> and the ISA interrupt routine gets just the device unit number. So the poll routine would normally look as:" ], "previous_source": "The poll function is used to simulate the interrupts when the interrupt subsystem is not functioning (for example, when the system has crashed and is creating the system dump). The CAM subsystem sets the proper interrupt level before calling the poll routine. So all it needs to do is to call the interrupt routine (or the other way around, the poll routine may be doing the real action and the interrupt routine would just call the poll routine). Why bother about a separate function then? Because of different calling conventions. The <function>xxx_poll</function> routine gets the struct cam_sim pointer as its argument when the PCI interrupt routine by common convention gets pointer to the struct <varname remap=\"structname\">xxx_softc</varname> and the ISA interrupt routine gets just the device unit number. So the poll routine would normally look as:", "target": [ "轮询函数用于当中断子系统不起作用时(例如,系统崩溃或正在创建 系统转储)模拟中断。CAM子系统在调用轮询函数前设置适当的中断级别。 因此它所需做全部的只是调用中断例程(或其他方法,轮询例程来 进行实际动作, 而中断例程只是调用轮询例程)。那么为什么要找麻烦 弄出一个单独的函数来呢?这是由于不同的调用约定。 <function>xxx_poll</function>例程取结构cam_sim的指针作为参量, 而PCI中断例程按照普通约定取的是指向结构 <varname remap=\"structname\">xxx_softc</varname>的指针,ISA中断例程只是取设备号, 因此轮询例程一般看起来像:" ], "id_hash": -3525007900071779886, "content_hash": -3525007900071779886, "location": "book.translate.xml:21089", "context": "", "note": "(itstool) path: sect1/para", "flags": "", "labels": [], "state": 10, "fuzzy": true, "translated": false, "approved": false, "position": 2336, "has_suggestion": false, "has_comment": false, "has_failing_check": false, "num_words": 135, "source_unit": "https://translate-dev.freebsd.org/api/units/229398/?format=api", "priority": 100, "id": 229462, "web_url": "https://translate-dev.freebsd.org/translate/freebsd-doc/boooks_arch-handbook/zh_CN/?checksum=4f14a7fdbdc6a1d2", "url": "https://translate-dev.freebsd.org/api/units/229462/?format=api", "explanation": "", "extra_flags": "", "pending": false, "timestamp": "2021-01-09T14:37:39.978604Z" }