요약·해설과 원문, 전문 번역을 서로 분리했습니다. API 이름, symbol, source path는 원문 표기를 사용합니다.
1. 요약·해설
원문의 핵심 논리와 kernel programming 관점의 보충 설명입니다. 아래의 전문 번역과는 별도로 작성했습니다.
2. 영어 원문 전체
번역 기준이 된 Linux v6.18.37 원문입니다. 줄 번호는 이 버전의 파일 좌표입니다.
원문 전체 펼치기
.. SPDX-License-Identifier: GPL-2.0
======================================
Linux SCSI Disk Driver (sd) Parameters
======================================
cache_type (RW)
---------------
Enable/disable drive write & read cache.
=========================== === === =========== ==========
cache_type string WCE RCD Write cache Read cache
=========================== === === =========== ==========
write through 0 0 off on
none 0 1 off off
write back 1 0 on on
write back, no read (daft) 1 1 on off
=========================== === === =========== ==========
To set cache type to "write back" and save this setting to the drive::
# echo "write back" > cache_type
To modify the caching mode without making the change persistent, prepend
"temporary " to the cache type string. E.g.::
# echo "temporary write back" > cache_type
3. 한국어 전문 번역
영어 원문의 문단 순서와 의미를 유지한 전체 번역입니다. 코드, 함수명, symbol과 URL은 원문 표기를 유지합니다.
cache_type과 WCE·RCD 조합
1-19읽고 쓸 수 있는 `cache_type` parameter는 drive의 write cache와 read cache를 켜거나 끈다. `WCE`는 write cache enable, `RCD`는 read cache disable bit다.
문자열과 WCE·RCD bit가 실제 cache 상태로 이어지는 방식이다.
.. SPDX-License-Identifier: GPL-2.0
======================================
Linux SCSI Disk Driver (sd) Parameters
======================================
cache_type (RW)
---------------
Enable/disable drive write & read cache.
=========================== === === =========== ==========
cache_type string WCE RCD Write cache Read cache
=========================== === === =========== ==========
write through 0 0 off on
none 0 1 off off
write back 1 0 on on
write back, no read (daft) 1 1 on off
=========================== === === =========== ==========
영구·임시 cache mode 설정
20-27Cache type을 `write back`으로 바꾸고 drive에 설정을 저장하려면 `echo "write back" > cache_type`을 실행한다.
변경을 영구 저장하지 않고 caching mode만 임시로 바꾸려면 cache type 문자열 앞에 `temporary `를 붙인다. 예를 들어 `echo "temporary write back" > cache_type`을 사용한다.
같은 mode라도 temporary 접두사로 persistence를 구분한다.
To set cache type to "write back" and save this setting to the drive::
# echo "write back" > cache_type
To modify the caching mode without making the change persistent, prepend
"temporary " to the cache type string. E.g.::
# echo "temporary write back" > cache_type
요약·해설
sd-parameters.rst:1-27sd driver의 cache_type 문자열과 write/read cache bit, 영구·임시 변경법을 설명합니다.