Units
Translation components API.
See the Weblate's Web API documentation for detailed description of the API.
GET /api/translations/freebsd-doc/boooks_arch-handbook/zh_CN/units/?format=api&page=55
https://translate-dev.freebsd.org/api/translations/freebsd-doc/boooks_arch-handbook/zh_CN/units/?format=api&page=54", "results": [ { "translation": "https://translate-dev.freebsd.org/api/translations/freebsd-doc/boooks_arch-handbook/zh_CN/?format=api", "source": [ "<personname> <firstname>Michael</firstname> <othername role=\"MI\">J</othername> <surname>Karels</surname> </personname>" ], "previous_source": "<personname><firstname>Michael</firstname><othername role=\"MI\">J</othername><surname>Karels</surname></personname>", "target": [ "<personname><firstname>Michael</firstname><othername role=\"MI\">J</othername><surname>Karels</surname></personname>" ], "id_hash": 3034677945306011853, "content_hash": 3034677945306011853, "location": "book.translate.xml:23930", "context": "", "note": "(itstool) path: authorgroup/author", "flags": "", "labels": [], "state": 10, "fuzzy": true, "translated": false, "approved": false, "position": 2715, "has_suggestion": false, "has_comment": false, "has_failing_check": false, "num_words": 6, "source_unit": "https://translate-dev.freebsd.org/api/units/92211/?format=api", "priority": 100, "id": 90432, "web_url": "https://translate-dev.freebsd.org/translate/freebsd-doc/boooks_arch-handbook/zh_CN/?checksum=aa1d578349ad58cd", "url": "https://translate-dev.freebsd.org/api/units/90432/?format=api", "explanation": "", "extra_flags": "", "pending": false, "timestamp": "2019-11-02T20:37:18.432906Z" }, { "translation": "https://translate-dev.freebsd.org/api/translations/freebsd-doc/boooks_arch-handbook/zh_CN/?format=api", "source": [ "<personname> <firstname>John</firstname> <othername role=\"MI\">S</othername> <surname>Quarterman</surname> </personname>" ], "previous_source": "<personname><firstname>John</firstname><othername role=\"MI\">S</othername><surname>Quarterman</surname></personname>", "target": [ "<personname><firstname>John</firstname><othername role=\"MI\">S</othername><surname>Quarterman</surname></personname>" ], "id_hash": -2603425401615862519, "content_hash": -2603425401615862519, "location": "book.translate.xml:23937", "context": "", "note": "(itstool) path: authorgroup/author", "flags": "", "labels": [], "state": 10, "fuzzy": true, "translated": false, "approved": false, "position": 2716, "has_suggestion": false, "has_comment": false, "has_failing_check": false, "num_words": 6, "source_unit": "https://translate-dev.freebsd.org/api/units/92212/?format=api", "priority": 100, "id": 90433, "web_url": "https://translate-dev.freebsd.org/translate/freebsd-doc/boooks_arch-handbook/zh_CN/?checksum=5bdec66409753509", "url": "https://translate-dev.freebsd.org/api/units/90433/?format=api", "explanation": "", "extra_flags": "", "pending": false, "timestamp": "2019-11-02T20:37:18.443382Z" }, { "translation": "https://translate-dev.freebsd.org/api/translations/freebsd-doc/boooks_arch-handbook/zh_CN/?format=api", "source": [ "The value of <literal>0xfffffff0</literal> is slightly less than 4 GB, so unless the machine has 4 GB of physical memory, it cannot point to a valid memory address. The computer's hardware translates this address so that it points to a <acronym>BIOS</acronym> memory block." ], "previous_source": "", "target": [ "值 <literal>0xfffffff0</literal> 略小于4G,因此计算机没有 4G 字节物理内存,这就不会是一个有效的内存地址。计算机硬件将这个地址转指向 <acronym>BIOS</acronym> 存储块。" ], "id_hash": -5189313260644394010, "content_hash": -5189313260644394010, "location": "book.translate.xml:426", "context": "", "note": "(itstool) path: sect1/para", "flags": "", "labels": [], "state": 20, "fuzzy": false, "translated": true, "approved": false, "position": 48, "has_suggestion": false, "has_comment": false, "has_failing_check": false, "num_words": 43, "source_unit": "https://translate-dev.freebsd.org/api/units/157530/?format=api", "priority": 100, "id": 157536, "web_url": "https://translate-dev.freebsd.org/translate/freebsd-doc/boooks_arch-handbook/zh_CN/?checksum=37fbdb1567111be6", "url": "https://translate-dev.freebsd.org/api/units/157536/?format=api", "explanation": "", "extra_flags": "", "pending": false, "timestamp": "2020-04-18T18:15:04.288929Z" }, { "translation": "https://translate-dev.freebsd.org/api/translations/freebsd-doc/boooks_arch-handbook/zh_CN/?format=api", "source": [ "An interrupt is requested with number <literal>0x1a</literal> and argument <literal>0</literal> in register <literal>%ah</literal>. The <acronym>BIOS</acronym> has a predefined set of services, requested by applications as software-generated interrupts through the <literal>int</literal> instruction and receiving arguments in registers (in this case, <literal>%ah</literal>). Here, particularly, we are requesting the number of clock ticks since last midnight; this value is computed by the <acronym>BIOS</acronym> through the <acronym>RTC</acronym> (Real Time Clock). This clock can be programmed to work at frequencies ranging from 2 Hz to 8192 Hz. The <acronym>BIOS</acronym> sets it to 18.2 Hz at startup. When the request is satisfied, a 32-bit result is returned by the <acronym>BIOS</acronym> in registers <literal>%cx</literal> and <literal>%dx</literal> (lower bytes in <literal>%dx</literal>). This result (the <literal>%dx</literal> part) is copied to register <literal>%di</literal>, and the value of the <varname>TICKS</varname> variable is added to <literal>%di</literal>. This variable resides in <filename>boot0</filename> at offset <literal>_TICKS</literal> (a negative value) from register <literal>%bp</literal> (which, recall, points to <literal>0x800</literal>). The default value of this variable is <literal>0xb6</literal> (182 in decimal). Now, the idea is that <filename>boot0</filename> constantly requests the time from the <acronym>BIOS</acronym>, and when the value returned in register <literal>%dx</literal> is greater than the value stored in <literal>%di</literal>, the time is up and the default selection will be made. Since the RTC ticks 18.2 times per second, this condition will be met after 10 seconds (this default behavior can be changed in the <filename>Makefile</filename>). Until this time has passed, <filename>boot0</filename> continually asks the <acronym>BIOS</acronym> for any user input; this is done through <literal>int 0x16</literal>, argument <literal>1</literal> in <literal>%ah</literal>." ], "previous_source": "", "target": [ "" ], "id_hash": -2307518497613111655, "content_hash": -2307518497613111655, "location": "book.translate.xml:858", "context": "", "note": "(itstool) path: sect1/para", "flags": "", "labels": [], "state": 0, "fuzzy": false, "translated": false, "approved": false, "position": 95, "has_suggestion": false, "has_comment": false, "has_failing_check": false, "num_words": 253, "source_unit": "https://translate-dev.freebsd.org/api/units/157532/?format=api", "priority": 100, "id": 157537, "web_url": "https://translate-dev.freebsd.org/translate/freebsd-doc/boooks_arch-handbook/zh_CN/?checksum=5ffa0c26f5209e99", "url": "https://translate-dev.freebsd.org/api/units/157537/?format=api", "explanation": "", "extra_flags": "", "pending": false, "timestamp": "2020-04-18T18:15:04.308649Z" }, { "translation": "https://translate-dev.freebsd.org/api/translations/freebsd-doc/boooks_arch-handbook/zh_CN/?format=api", "source": [ "Example of a Sample Echo Pseudo-Device Driver for FreeBSD 10.X - 12.X" ], "previous_source": "Example of a Sample Echo Pseudo-Device Driver for FreeBSD 10.X - 12.X", "target": [ "适用于 FreeBSD 10.X - 12.X 的回显伪设备驱动程序实例" ], "id_hash": 9144301548006342219, "content_hash": 9144301548006342219, "location": "book.translate.xml:16259", "context": "", "note": "(itstool) path: example/title", "flags": "", "labels": [], "state": 10, "fuzzy": true, "translated": false, "approved": false, "position": 1705, "has_suggestion": false, "has_comment": false, "has_failing_check": false, "num_words": 12, "source_unit": "https://translate-dev.freebsd.org/api/units/157534/?format=api", "priority": 100, "id": 157538, "web_url": "https://translate-dev.freebsd.org/translate/freebsd-doc/boooks_arch-handbook/zh_CN/?checksum=fee715cf2ff8fe4b", "url": "https://translate-dev.freebsd.org/api/units/157538/?format=api", "explanation": "", "extra_flags": "", "pending": false, "timestamp": "2020-04-18T18:15:04.539717Z" }, { "translation": "https://translate-dev.freebsd.org/api/translations/freebsd-doc/boooks_arch-handbook/zh_CN/?format=api", "source": [ "$FreeBSD$" ], "previous_source": "", "target": [ "" ], "id_hash": -6157127918850188850, "content_hash": -6157127918850188850, "location": "book.translate.xml:147, book.translate.xml:226", "context": "", "note": "(itstool) path: info/pubdate\n(itstool) path: info/releaseinfo", "flags": "", "labels": [], "state": 0, "fuzzy": false, "translated": false, "approved": false, "position": 4, "has_suggestion": false, "has_comment": false, "has_failing_check": false, "num_words": 1, "source_unit": "https://translate-dev.freebsd.org/api/units/229385/?format=api", "priority": 100, "id": 229449, "web_url": "https://translate-dev.freebsd.org/translate/freebsd-doc/boooks_arch-handbook/zh_CN/?checksum=2a8d7cc7984b59ce", "url": "https://translate-dev.freebsd.org/api/units/229449/?format=api", "explanation": "", "extra_flags": "", "pending": false, "timestamp": "2021-01-09T14:37:35.970782Z" }, { "translation": "https://translate-dev.freebsd.org/api/translations/freebsd-doc/boooks_arch-handbook/zh_CN/?format=api", "source": [ "As <filename>boot0</filename> is loaded by the <acronym>BIOS</acronym> to address <literal>0x7C00</literal>, it copies itself to address <literal>0x600</literal> and then transfers control there (recall that it was linked to execute at address <literal>0x600</literal>). The source address, <literal>0x7c00</literal>, is copied to register <literal>%si</literal>. The destination address, <literal>0x600</literal>, to register <literal>%di</literal>. The number of bytes to copy, <literal>512</literal> (the program's size), is copied to register <literal>%cx</literal>. Next, the <literal>rep</literal> instruction repeats the instruction that follows, that is, <literal>movsb</literal>, the number of times dictated by the <literal>%cx</literal> register. The <literal>movsb</literal> instruction copies the byte pointed to by <literal>%si</literal> to the address pointed to by <literal>%di</literal>. This is repeated another 511 times. On each repetition, both the source and destination registers, <literal>%si</literal> and <literal>%di</literal>, are incremented by one. Thus, upon completion of the 512-byte copy, <literal>%di</literal> has the value <literal>0x600</literal>+<literal>512</literal>= <literal>0x800</literal>, and <literal>%si</literal> has the value <literal>0x7c00</literal>+<literal>512</literal>= <literal>0x7e00</literal>; we have thus completed the code <emphasis>relocation</emphasis>." ], "previous_source": "", "target": [ "" ], "id_hash": 7019296161213301053, "content_hash": 7019296161213301053, "location": "book.translate.xml:650", "context": "", "note": "(itstool) path: sect1/para", "flags": "", "labels": [], "state": 0, "fuzzy": false, "translated": false, "approved": false, "position": 77, "has_suggestion": false, "has_comment": false, "has_failing_check": false, "num_words": 149, "source_unit": "https://translate-dev.freebsd.org/api/units/229386/?format=api", "priority": 100, "id": 229450, "web_url": "https://translate-dev.freebsd.org/translate/freebsd-doc/boooks_arch-handbook/zh_CN/?checksum=e1698cab3661c13d", "url": "https://translate-dev.freebsd.org/api/units/229450/?format=api", "explanation": "", "extra_flags": "", "pending": false, "timestamp": "2021-01-09T14:37:36.096678Z" }, { "translation": "https://translate-dev.freebsd.org/api/translations/freebsd-doc/boooks_arch-handbook/zh_CN/?format=api", "source": [ "So <filename>boot1</filename> occupies exactly the first 512 bytes of <filename>boot</filename> and, because <filename>boot</filename> is written to the first sector of the FreeBSD slice, <filename>boot1</filename> fits exactly in this first sector. When <literal>nread</literal> reads the first 16 sectors of the FreeBSD slice, it effectively reads the entire <filename>boot</filename> file <_:footnote-1/>. We will see more details about how <filename>boot</filename> is formed from <filename>boot1</filename> and <filename>boot2</filename> in the next section." ], "previous_source": "", "target": [ "" ], "id_hash": 4770993697178643548, "content_hash": 4770993697178643548, "location": "book.translate.xml:1263", "context": "", "note": "(itstool) path: sect1/para", "flags": "", "labels": [], "state": 0, "fuzzy": false, "translated": false, "approved": false, "position": 137, "has_suggestion": false, "has_comment": false, "has_failing_check": false, "num_words": 67, "source_unit": "https://translate-dev.freebsd.org/api/units/229387/?format=api", "priority": 100, "id": 229451, "web_url": "https://translate-dev.freebsd.org/translate/freebsd-doc/boooks_arch-handbook/zh_CN/?checksum=c235f97d61f5ec5c", "url": "https://translate-dev.freebsd.org/api/units/229451/?format=api", "explanation": "", "extra_flags": "", "pending": false, "timestamp": "2021-01-09T14:37:36.216387Z" }, { "translation": "https://translate-dev.freebsd.org/api/translations/freebsd-doc/boooks_arch-handbook/zh_CN/?format=api", "source": [ "This code disables interrupts, sets up a working stack (starting at address <literal>0x1800</literal>) and clears the flags in the EFLAGS register. Note that the <literal>popfl</literal> instruction pops out a doubleword (4 bytes) from the stack and places it in the EFLAGS register. As the value actually popped is <literal>2</literal>, the EFLAGS register is effectively cleared (IA-32 requires that bit 2 of the EFLAGS register always be 1)." ], "previous_source": "", "target": [ "" ], "id_hash": 3529489275754486430, "content_hash": 3529489275754486430, "location": "book.translate.xml:1680", "context": "", "note": "(itstool) path: sect1/para", "flags": "", "labels": [], "state": 0, "fuzzy": false, "translated": false, "approved": false, "position": 179, "has_suggestion": false, "has_comment": false, "has_failing_check": false, "num_words": 67, "source_unit": "https://translate-dev.freebsd.org/api/units/229388/?format=api", "priority": 100, "id": 229452, "web_url": "https://translate-dev.freebsd.org/translate/freebsd-doc/boooks_arch-handbook/zh_CN/?checksum=b0fb43cbd7e59a9e", "url": "https://translate-dev.freebsd.org/api/units/229452/?format=api", "explanation": "", "extra_flags": "", "pending": false, "timestamp": "2021-01-09T14:37:36.297600Z" }, { "translation": "https://translate-dev.freebsd.org/api/translations/freebsd-doc/boooks_arch-handbook/zh_CN/?format=api", "source": [ "The next step is to initialize the <acronym>TSS</acronym> (Task-State Segment). The <acronym>TSS</acronym> is a hardware feature that helps the operating system or executive software implement multitasking functionality through process abstraction. The IA-32 architecture demands the creation and use of <emphasis>at least</emphasis> one <acronym>TSS</acronym> if multitasking facilities are used or different privilege levels are defined. Since the <filename>boot2</filename> client is executed in privilege level 3, but the <acronym>BTX</acronym> server does in privilege level 0, a <acronym>TSS</acronym> must be defined:" ], "previous_source": "", "target": [ "" ], "id_hash": 5754700705504977385, "content_hash": 5754700705504977385, "location": "book.translate.xml:1821", "context": "", "note": "(itstool) path: sect1/para", "flags": "", "labels": [], "state": 0, "fuzzy": false, "translated": false, "approved": false, "position": 188, "has_suggestion": false, "has_comment": false, "has_failing_check": false, "num_words": 78, "source_unit": "https://translate-dev.freebsd.org/api/units/229389/?format=api", "priority": 100, "id": 229453, "web_url": "https://translate-dev.freebsd.org/translate/freebsd-doc/boooks_arch-handbook/zh_CN/?checksum=cfdccdcd4c5061e9", "url": "https://translate-dev.freebsd.org/api/units/229453/?format=api", "explanation": "", "extra_flags": "", "pending": false, "timestamp": "2021-01-09T14:37:36.320249Z" }, { "translation": "https://translate-dev.freebsd.org/api/translations/freebsd-doc/boooks_arch-handbook/zh_CN/?format=api", "source": [ "For this reason, no serious applications rely on block devices, and in fact, almost all applications which access disks directly take great pains to specify that character (or <quote>raw</quote>) devices should always be used. As the implementation of the aliasing of each disk (partition) to two devices with different semantics significantly complicated the relevant kernel code, FreeBSD dropped support for cached disk devices as part of the modernization of the disk I/O infrastructure." ], "previous_source": "", "target": [ "" ], "id_hash": -2770740314132742407, "content_hash": -2770740314132742407, "location": "book.translate.xml:16461", "context": "", "note": "(itstool) path: sect1/para", "flags": "", "labels": [], "state": 0, "fuzzy": false, "translated": false, "approved": false, "position": 1714, "has_suggestion": false, "has_comment": false, "has_failing_check": false, "num_words": 73, "source_unit": "https://translate-dev.freebsd.org/api/units/229390/?format=api", "priority": 100, "id": 229454, "web_url": "https://translate-dev.freebsd.org/translate/freebsd-doc/boooks_arch-handbook/zh_CN/?checksum=598c5a5d43437ef9", "url": "https://translate-dev.freebsd.org/api/units/229454/?format=api", "explanation": "", "extra_flags": "", "pending": false, "timestamp": "2021-01-09T14:37:38.855127Z" }, { "translation": "https://translate-dev.freebsd.org/api/translations/freebsd-doc/boooks_arch-handbook/zh_CN/?format=api", "source": [ "As the PnP devices are disabled when probing the legacy devices they will not be attached twice (once as legacy and once as PnP). But in case of device-dependent identify routines it is the responsibility of the driver to make sure that the same device will not be attached by the driver twice: once as legacy user-configured and once as auto-identified." ], "previous_source": "Because the PnP devices are disabled when probing the legacy devices they will not be attached twice (once as legacy and once as PnP). But in case of device-dependent identify routines it is the responsibility of the driver to make sure that the same device will not be attached by the driver twice: once as legacy user-configured and once as auto-identified.", "target": [ "由于探测老设备的时候PnP设备被禁用,它们不会被连接两次(一次作为老设备,一次作为PnP)。但如果识别例程设备相关的,这种情况下设备驱动程序有责任确保同一设备不会被设备驱动程序连接两次:一次作为老的由用户配置的,一次作为自动识别的。" ], "id_hash": 651447676183407919, "content_hash": 651447676183407919, "location": "book.translate.xml:16866", "context": "", "note": "(itstool) path: sect1/para", "flags": "", "labels": [], "state": 10, "fuzzy": true, "translated": false, "approved": false, "position": 1791, "has_suggestion": false, "has_comment": false, "has_failing_check": false, "num_words": 61, "source_unit": "https://translate-dev.freebsd.org/api/units/229391/?format=api", "priority": 100, "id": 229455, "web_url": "https://translate-dev.freebsd.org/translate/freebsd-doc/boooks_arch-handbook/zh_CN/?checksum=890a6835c0aa6d2f", "url": "https://translate-dev.freebsd.org/api/units/229455/?format=api", "explanation": "", "extra_flags": "", "pending": false, "timestamp": "2021-01-09T14:37:38.986221Z" }, { "translation": "https://translate-dev.freebsd.org/api/translations/freebsd-doc/boooks_arch-handbook/zh_CN/?format=api", "source": [ "Free the memory allocated by <function>bus_dmamem_alloc()</function>. At present, freeing of the memory allocated with ISA restrictions is not implemented. Due to this the recommended model of use is to keep and re-use the allocated areas for as long as possible. Do not lightly free some area and then shortly allocate it again. That does not mean that <function>bus_dmamem_free()</function> should not be used at all: hopefully it will be properly implemented soon." ], "previous_source": "Free the memory allocated by <function>bus_dmamem_alloc()</function>. At present, freeing of the memory allocated with ISA restrictions is not implemented. Because of this the recommended model of use is to keep and re-use the allocated areas for as long as possible. Do not lightly free some area and then shortly allocate it again. That does not mean that <function>bus_dmamem_free()</function> should not be used at all: hopefully it will be properly implemented soon.", "target": [ "释放由<function>bus_dmamem_alloc()</function>分配的内存。目前,对分配的带有ISA限制的内存的释放没有实现。因此,建议的使用模型为尽可能长时间地保持和重用分配的区域。不要轻易地释放某些区域,然后再短时间地分配它。这并不意味着不应当使用<function>bus_dmamem_free()</function>:希望很快它就会被完整地实现。" ], "id_hash": -7771074710491260305, "content_hash": -7771074710491260305, "location": "book.translate.xml:17506", "context": "", "note": "(itstool) path: listitem/para", "flags": "", "labels": [], "state": 10, "fuzzy": true, "translated": false, "approved": false, "position": 1897, "has_suggestion": false, "has_comment": false, "has_failing_check": false, "num_words": 71, "source_unit": "https://translate-dev.freebsd.org/api/units/229392/?format=api", "priority": 100, "id": 229456, "web_url": "https://translate-dev.freebsd.org/translate/freebsd-doc/boooks_arch-handbook/zh_CN/?checksum=142798b946259a6f", "url": "https://translate-dev.freebsd.org/api/units/229456/?format=api", "explanation": "", "extra_flags": "", "pending": false, "timestamp": "2021-01-09T14:37:39.167188Z" }, { "translation": "https://translate-dev.freebsd.org/api/translations/freebsd-doc/boooks_arch-handbook/zh_CN/?format=api", "source": [ "Before calling the callback function from <function>bus_dmamap_load()</function> the segment array is stored in the stack. And it gets pre-allocated for the maximal number of segments allowed by the tag. As a result of this the practical limit for the number of segments on i386 architecture is about 250-300 (the kernel stack is 4KB minus the size of the user structure, size of a segment array entry is 8 bytes, and some space must be left). Since the array is allocated based on the maximal number this value must not be set higher than really needed. Fortunately, for most of hardware the maximal supported number of segments is much lower. But if the driver wants to handle buffers with a very large number of scatter-gather segments it should do that in portions: load part of the buffer, transfer it to the device, load next part of the buffer, and so on." ], "previous_source": "Before calling the callback function from <function>bus_dmamap_load()</function> the segment array is stored in the stack. And it gets pre-allocated for the maximal number of segments allowed by the tag. Because of this the practical limit for the number of segments on i386 architecture is about 250-300 (the kernel stack is 4KB minus the size of the user structure, size of a segment array entry is 8 bytes, and some space must be left). Because the array is allocated based on the maximal number this value must not be set higher than really needed. Fortunately, for most of hardware the maximal supported number of segments is much lower. But if the driver wants to handle buffers with a very large number of scatter-gather segments it should do that in portions: load part of the buffer, transfer it to the device, load next part of the buffer, and so on.", "target": [ "从<function>bus_dmamap_load()</function>中调用回调函数之前,段数组是存储在栈中的。并且是按标签允许的最大数目的段预先分配好的。这样由于i386体系结构上对段数目的实际限制约为250-300(内核栈为4KB减去用户结构的大小,段数组条目的大小为8字节,和其它必须留出来的空间)。由于数组基于最大数目而分配,因此这个值必须不能设置成超出实际需要。幸运的是,对于大多数硬件而言,所支持的段的最大数目低很多。但如果驱动程序想处理具有非常多分散/收集段的缓冲区,则应当一部分一部分地处理:加载缓冲区的一部分,传输到设备,然后加载缓冲区的下一部分,如此反复。" ], "id_hash": 5944484303631366233, "content_hash": 5944484303631366233, "location": "book.translate.xml:17809", "context": "", "note": "(itstool) path: sect1/para", "flags": "", "labels": [], "state": 10, "fuzzy": true, "translated": false, "approved": false, "position": 1935, "has_suggestion": false, "has_comment": false, "has_failing_check": false, "num_words": 150, "source_unit": "https://translate-dev.freebsd.org/api/units/229393/?format=api", "priority": 100, "id": 229457, "web_url": "https://translate-dev.freebsd.org/translate/freebsd-doc/boooks_arch-handbook/zh_CN/?checksum=d27f0cfa9ad53859", "url": "https://translate-dev.freebsd.org/api/units/229457/?format=api", "explanation": "", "extra_flags": "", "pending": false, "timestamp": "2021-01-09T14:37:39.238470Z" }, { "translation": "https://translate-dev.freebsd.org/api/translations/freebsd-doc/boooks_arch-handbook/zh_CN/?format=api", "source": [ "Then allocate and activate all the necessary resources. As normally the port range will be released before returning from probe, it has to be allocated again. We expect that the probe routine had properly set all the resource ranges, as well as saved them in the structure softc. If the probe routine had left some resource allocated then it does not need to be allocated again (which would be considered an error)." ], "previous_source": "Then allocate and activate all the necessary resources. Because normally the port range will be released before returning from probe, it has to be allocated again. We expect that the probe routine had properly set all the resource ranges, as well as saved them in the structure softc. If the probe routine had left some resource allocated then it does not need to be allocated again (which would be considered an error).", "target": [ "然后分配并激活所需资源。由于端口范围通常在从探测返回前就被释放,因此需要重新分配。我们希望探测例程已经适当地设置了所有的资源范围,并将它们保存在结构softc中。如果探测例程留下了一些被分配的资源,就不需要再次分配(重新分配被视为错误)。" ], "id_hash": -5461918463108398047, "content_hash": -5461918463108398047, "location": "book.translate.xml:18682", "context": "", "note": "(itstool) path: sect1/para", "flags": "", "labels": [], "state": 10, "fuzzy": true, "translated": false, "approved": false, "position": 2026, "has_suggestion": false, "has_comment": false, "has_failing_check": false, "num_words": 72, "source_unit": "https://translate-dev.freebsd.org/api/units/229394/?format=api", "priority": 100, "id": 229458, "web_url": "https://translate-dev.freebsd.org/translate/freebsd-doc/boooks_arch-handbook/zh_CN/?checksum=34335e18a646c421", "url": "https://translate-dev.freebsd.org/api/units/229458/?format=api", "explanation": "", "extra_flags": "", "pending": false, "timestamp": "2021-01-09T14:37:39.416086Z" }, { "translation": "https://translate-dev.freebsd.org/api/translations/freebsd-doc/boooks_arch-handbook/zh_CN/?format=api", "source": [ "As we are interested in writing a SCSI adapter driver here, from this point on we will consider everything from the SIM standpoint." ], "previous_source": "Because we are interested in writing a SCSI adapter driver here, from this point on we will consider everything from the SIM standpoint.", "target": [ "由于这儿我们感兴趣的是编写SCSI适配器驱动程序,从此处开始我们将从SIM的角度考虑所有的事情。" ], "id_hash": -3885103319677610175, "content_hash": -3885103319677610175, "location": "book.translate.xml:19566", "context": "", "note": "(itstool) path: sect1/para", "flags": "", "labels": [], "state": 10, "fuzzy": true, "translated": false, "approved": false, "position": 2124, "has_suggestion": false, "has_comment": false, "has_failing_check": false, "num_words": 23, "source_unit": "https://translate-dev.freebsd.org/api/units/229395/?format=api", "priority": 100, "id": 229459, "web_url": "https://translate-dev.freebsd.org/translate/freebsd-doc/boooks_arch-handbook/zh_CN/?checksum=4a15571d6aecd741", "url": "https://translate-dev.freebsd.org/api/units/229459/?format=api", "explanation": "", "extra_flags": "", "pending": false, "timestamp": "2021-01-09T14:37:39.592316Z" }, { "translation": "https://translate-dev.freebsd.org/api/translations/freebsd-doc/boooks_arch-handbook/zh_CN/?format=api", "source": [ "If the CCB is being transferred right now we would like to signal to the SCSI controller in some hardware-dependent way that we want to abort the current transfer. The SCSI controller would set the SCSI ATTENTION signal and when the target responds to it send an ABORT message. We also reset the timeout to make sure that the target is not sleeping forever. If the command would not get aborted in some reasonable time like 10 seconds the timeout routine would go ahead and reset the whole SCSI bus. Since the command will be aborted in some reasonable time we can just return the abort request now as successfully completed, and mark the aborted CCB as aborted (but not mark it as done yet)." ], "previous_source": "If the CCB is being transferred right now we would like to signal to the SCSI controller in some hardware-dependent way that we want to abort the current transfer. The SCSI controller would set the SCSI ATTENTION signal and when the target responds to it send an ABORT message. We also reset the timeout to make sure that the target is not sleeping forever. If the command would not get aborted in some reasonable time like 10 seconds the timeout routine would go ahead and reset the whole SCSI bus. Because the command will be aborted in some reasonable time we can just return the abort request now as successfully completed, and mark the aborted CCB as aborted (but not mark it as done yet).", "target": [ "如果CCB此时正在传输中,我们一般会以某种硬件相关的方式发信号 给SCSI控制器,通知它我们希望中止当前的传输。SCSI控制器会设置 SCSI ATTENTION信号,并当目标对其进行响应后发送ABORT消息。我们也复位 超时,以确保目标不会永远睡眠。如果命令不能在某个合理的时间,如 10秒内中止,超时例程就会运行并复位整个SCSI总线。由于命令会在某个 合理的时间后被中止,因此我们现在可以只将中止请求返回,当作成功完成, 并将被中止的CCB标记为中止(但还没有将它标记为完成)。" ], "id_hash": -2897232973491234230, "content_hash": -2897232973491234230, "location": "book.translate.xml:20531", "context": "", "note": "(itstool) path: listitem/para", "flags": "", "labels": [], "state": 10, "fuzzy": true, "translated": false, "approved": false, "position": 2254, "has_suggestion": false, "has_comment": false, "has_failing_check": false, "num_words": 125, "source_unit": "https://translate-dev.freebsd.org/api/units/229396/?format=api", "priority": 100, "id": 229460, "web_url": "https://translate-dev.freebsd.org/translate/freebsd-doc/boooks_arch-handbook/zh_CN/?checksum=57caf5f5f7819a4a", "url": "https://translate-dev.freebsd.org/api/units/229460/?format=api", "explanation": "", "extra_flags": "", "pending": false, "timestamp": "2021-01-09T14:37:39.823734Z" }, { "translation": "https://translate-dev.freebsd.org/api/translations/freebsd-doc/boooks_arch-handbook/zh_CN/?format=api", "source": [ "That is all for the ABORT request, although there is one more issue. As the ABORT message cleans all the ongoing transactions on a LUN we have to mark all the other active transactions on this LUN as aborted. That should be done in the interrupt routine, after the transaction gets aborted." ], "previous_source": "That is all for the ABORT request, although there is one more issue. Because the ABORT message cleans all the ongoing transactions on a LUN we have to mark all the other active transactions on this LUN as aborted. That should be done in the interrupt routine, after the transaction gets aborted.", "target": [ "这就是关于ABORT请求的全部,尽管还有一个问题。由于ABORT消息 清除LUN上所有正在进行中的事务,我们必须将LUN上所有其他活动事务 标记为中止。那应当在中断例程中完成,且在中止事务之后。" ], "id_hash": -3249575469728956370, "content_hash": -3249575469728956370, "location": "book.translate.xml:20578", "context": "", "note": "(itstool) path: listitem/para", "flags": "", "labels": [], "state": 10, "fuzzy": true, "translated": false, "approved": false, "position": 2258, "has_suggestion": false, "has_comment": false, "has_failing_check": false, "num_words": 52, "source_unit": "https://translate-dev.freebsd.org/api/units/229397/?format=api", "priority": 100, "id": 229461, "web_url": "https://translate-dev.freebsd.org/translate/freebsd-doc/boooks_arch-handbook/zh_CN/?checksum=52e73053c7fb802e", "url": "https://translate-dev.freebsd.org/api/units/229461/?format=api", "explanation": "", "extra_flags": "", "pending": false, "timestamp": "2021-01-09T14:37:39.839516Z" }, { "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" }, { "translation": "https://translate-dev.freebsd.org/api/translations/freebsd-doc/boooks_arch-handbook/zh_CN/?format=api", "source": [ "Example: Firmware download Many devices that have been developed are based on a general purpose processor with an additional USB core added to it. Since the development of drivers and firmware for USB devices is still very new, many devices require the downloading of the firmware after they have been connected." ], "previous_source": "Example: Firmware download Many devices that have been developed are based on a general purpose processor with an additional USB core added to it. Because the development of drivers and firmware for USB devices is still very new, many devices require the downloading of the firmware after they have been connected.", "target": [ "例子:固件下载。已经开发出来的许多设备是基于通用目的处理器, 并将额外的USB核心加入其中。由于驱动程序的开发和USB设备的固件仍然 非常新,许多设备需要在连接(connect)之后下载固件。" ], "id_hash": -2354564052656662415, "content_hash": -2354564052656662415, "location": "book.translate.xml:22363", "context": "", "note": "(itstool) path: sect1/para", "flags": "", "labels": [], "state": 10, "fuzzy": true, "translated": false, "approved": false, "position": 2480, "has_suggestion": false, "has_comment": false, "has_failing_check": false, "num_words": 51, "source_unit": "https://translate-dev.freebsd.org/api/units/229399/?format=api", "priority": 100, "id": 229463, "web_url": "https://translate-dev.freebsd.org/translate/freebsd-doc/boooks_arch-handbook/zh_CN/?checksum=5f52e878187ed871", "url": "https://translate-dev.freebsd.org/api/units/229463/?format=api", "explanation": "", "extra_flags": "", "pending": false, "timestamp": "2021-01-09T14:37:40.230171Z" }, { "translation": "https://translate-dev.freebsd.org/api/translations/freebsd-doc/boooks_arch-handbook/zh_CN/?format=api", "source": [ "Due to this practice, FreeBSD drivers usually rely on numeric IDs for device identification. Using numeric IDs and a centralized database complicates adding IDs and support for cards to the system. One must carefully check to see who really made the card, especially when it appears that the vendor who made the card might already have a different manufacturer ID listed in the central database. Linksys, D-Link, and NetGear are a number of US manufacturers of LAN hardware that often sell the same design. These same designs can be sold in Japan under names such as Buffalo and Corega. Often, these devices will all have the same manufacturer and product IDs." ], "previous_source": "Because of this practice, FreeBSD drivers usually rely on numeric IDs for device identification. Using numeric IDs and a centralized database complicates adding IDs and support for cards to the system. One must carefully check to see who really made the card, especially when it appears that the vendor who made the card might already have a different manufacturer ID listed in the central database. Linksys, D-Link, and NetGear are a number of US manufacturers of LAN hardware that often sell the same design. These same designs can be sold in Japan under names such as Buffalo and Corega. Often, these devices will all have the same manufacturer and product IDs.", "target": [ "鉴于以上情况,对于FreeBSD来说使用数字ID可以减小工作量。同时也 会减小将ID加入到系统的过程中所带来的复杂性。必须仔细检查谁是卡的 真正制造者,尤其当提供原卡的供货商在中心数据库中已经有一个不同的ID 时。Linksys,D-Link和NetGear是经常出售相同设计的几个美国制造商。 相同的设计可能在日本以诸如Buffalo和Corega的名字出售。然而,这些 设备常常具有相同的制造商和产品ID。" ], "id_hash": 2257468920577724449, "content_hash": 2257468920577724449, "location": "book.translate.xml:23559", "context": "", "note": "(itstool) path: sect2/para", "flags": "", "labels": [], "state": 10, "fuzzy": true, "translated": false, "approved": false, "position": 2675, "has_suggestion": false, "has_comment": false, "has_failing_check": false, "num_words": 111, "source_unit": "https://translate-dev.freebsd.org/api/units/229400/?format=api", "priority": 100, "id": 229464, "web_url": "https://translate-dev.freebsd.org/translate/freebsd-doc/boooks_arch-handbook/zh_CN/?checksum=9f542405ce851021", "url": "https://translate-dev.freebsd.org/api/units/229464/?format=api", "explanation": "", "extra_flags": "", "pending": false, "timestamp": "2021-01-09T14:37:40.567330Z" } ] }{ "count": 2721, "next": null, "previous": "