Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

Merge branch 'pdf_fixes_v1' of https://git.linuxtv.org/mchehab/experimental into mauro

Bring in a set of post-thrashup fixes from Mauro.

+739 -679
+4 -1
Documentation/PCI/pci-error-recovery.rst
··· 403 403 .. note:: 404 404 405 405 Implementation details for the powerpc platform are discussed in 406 - the file Documentation/powerpc/eeh-pci-error-recovery.txt 406 + the file Documentation/powerpc/eeh-pci-error-recovery.rst 407 407 408 408 As of this writing, there is a growing list of device drivers with 409 409 patches implementing error recovery. Not all of these patches are in ··· 422 422 - drivers/net/cxgb3 423 423 - drivers/net/s2io.c 424 424 - drivers/net/qlge 425 + 426 + The End 427 + -------
+1 -1
Documentation/RCU/rculist_nulls.txt
··· 1 1 Using hlist_nulls to protect read-mostly linked lists and 2 2 objects using SLAB_TYPESAFE_BY_RCU allocations. 3 3 4 - Please read the basics in Documentation/RCU/listRCU.txt 4 + Please read the basics in Documentation/RCU/listRCU.rst 5 5 6 6 Using special makers (called 'nulls') is a convenient way 7 7 to solve following problem :
-10
Documentation/admin-guide/conf.py
··· 1 - # -*- coding: utf-8; mode: python -*- 2 - 3 - project = 'Linux Kernel User Documentation' 4 - 5 - tags.add("subproject") 6 - 7 - latex_documents = [ 8 - ('index', 'linux-user.tex', 'Linux Kernel User Documentation', 9 - 'The kernel development community', 'manual'), 10 - ]
+29 -1
Documentation/conf.py
··· 16 16 import os 17 17 import sphinx 18 18 19 + from subprocess import check_output 20 + 19 21 # Get Sphinx version 20 22 major, minor, patch = sphinx.version_info[:3] 21 23 ··· 278 276 \\setsansfont{DejaVu Sans} 279 277 \\setromanfont{DejaVu Serif} 280 278 \\setmonofont{DejaVu Sans Mono} 281 - 282 279 ''' 283 280 } 281 + 282 + # At least one book (translations) may have Asian characters 283 + # with are only displayed if xeCJK is used 284 + 285 + cjk_cmd = check_output(['fc-list', '--format="%{family[0]}\n"']).decode('utf-8', 'ignore') 286 + if cjk_cmd.find("Noto Sans CJK SC") >= 0: 287 + print ("enabling CJK for LaTeX builder") 288 + latex_elements['preamble'] += ''' 289 + % This is needed for translations 290 + \\usepackage{xeCJK} 291 + \\setCJKmainfont{Noto Sans CJK SC} 292 + ''' 284 293 285 294 # Fix reference escape troubles with Sphinx 1.4.x 286 295 if major == 1 and minor > 3: ··· 422 409 ('userspace-api/index', 'userspace-api.tex', 'The Linux kernel user-space API guide', 423 410 'The kernel development community', 'manual'), 424 411 ] 412 + 413 + # Add all other index files from Documentation/ subdirectories 414 + for fn in os.listdir('.'): 415 + doc = os.path.join(fn, "index") 416 + if os.path.exists(doc + ".rst"): 417 + has = False 418 + for l in latex_documents: 419 + if l[0] == doc: 420 + has = True 421 + break 422 + if not has: 423 + latex_documents.append((doc, fn + '.tex', 424 + 'Linux %s Documentation' % fn.capitalize(), 425 + 'The kernel development community', 426 + 'manual')) 425 427 426 428 # The name of an image file (relative to this directory) to place at the top of 427 429 # the title page.
-10
Documentation/core-api/conf.py
··· 1 - # -*- coding: utf-8; mode: python -*- 2 - 3 - project = "Core-API Documentation" 4 - 5 - tags.add("subproject") 6 - 7 - latex_documents = [ 8 - ('index', 'core-api.tex', project, 9 - 'The kernel development community', 'manual'), 10 - ]
-10
Documentation/crypto/conf.py
··· 1 - # -*- coding: utf-8; mode: python -*- 2 - 3 - project = 'Linux Kernel Crypto API' 4 - 5 - tags.add("subproject") 6 - 7 - latex_documents = [ 8 - ('index', 'crypto-api.tex', 'Linux Kernel Crypto API manual', 9 - 'The kernel development community', 'manual'), 10 - ]
-10
Documentation/dev-tools/conf.py
··· 1 - # -*- coding: utf-8; mode: python -*- 2 - 3 - project = "Development tools for the kernel" 4 - 5 - tags.add("subproject") 6 - 7 - latex_documents = [ 8 - ('index', 'dev-tools.tex', project, 9 - 'The kernel development community', 'manual'), 10 - ]
+1 -1
Documentation/devicetree/bindings/arm/idle-states.txt
··· 703 703 https://www.devicetree.org/specifications/ 704 704 705 705 [6] ARM Linux Kernel documentation - Booting AArch64 Linux 706 - Documentation/arm64/booting.txt 706 + Documentation/arm64/booting.rst
-10
Documentation/doc-guide/conf.py
··· 1 - # -*- coding: utf-8; mode: python -*- 2 - 3 - project = 'Linux Kernel Documentation Guide' 4 - 5 - tags.add("subproject") 6 - 7 - latex_documents = [ 8 - ('index', 'kernel-doc-guide.tex', 'Linux Kernel Documentation Guide', 9 - 'The kernel development community', 'manual'), 10 - ]
-10
Documentation/driver-api/80211/conf.py
··· 1 - # -*- coding: utf-8; mode: python -*- 2 - 3 - project = "Linux 802.11 Driver Developer's Guide" 4 - 5 - tags.add("subproject") 6 - 7 - latex_documents = [ 8 - ('index', '80211.tex', project, 9 - 'The kernel development community', 'manual'), 10 - ]
-10
Documentation/driver-api/conf.py
··· 1 - # -*- coding: utf-8; mode: python -*- 2 - 3 - project = "The Linux driver implementer's API guide" 4 - 5 - tags.add("subproject") 6 - 7 - latex_documents = [ 8 - ('index', 'driver-api.tex', project, 9 - 'The kernel development community', 'manual'), 10 - ]
-10
Documentation/driver-api/pm/conf.py
··· 1 - # -*- coding: utf-8; mode: python -*- 2 - 3 - project = "Device Power Management" 4 - 5 - tags.add("subproject") 6 - 7 - latex_documents = [ 8 - ('index', 'pm.tex', project, 9 - 'The kernel development community', 'manual'), 10 - ]
-10
Documentation/filesystems/conf.py
··· 1 - # -*- coding: utf-8; mode: python -*- 2 - 3 - project = "Linux Filesystems API" 4 - 5 - tags.add("subproject") 6 - 7 - latex_documents = [ 8 - ('index', 'filesystems.tex', project, 9 - 'The kernel development community', 'manual'), 10 - ]
-10
Documentation/gpu/conf.py
··· 1 - # -*- coding: utf-8; mode: python -*- 2 - 3 - project = "Linux GPU Driver Developer's Guide" 4 - 5 - tags.add("subproject") 6 - 7 - latex_documents = [ 8 - ('index', 'gpu.tex', project, 9 - 'The kernel development community', 'manual'), 10 - ]
+3
Documentation/index.rst
··· 111 111 netlabel/index 112 112 networking/index 113 113 pcmcia/index 114 + power/index 114 115 target/index 115 116 timers/index 116 117 watchdog/index 118 + virtual/index 117 119 input/index 118 120 hwmon/index 119 121 gpu/index ··· 145 143 arm64/index 146 144 ia64/index 147 145 m68k/index 146 + powerpc/index 148 147 riscv/index 149 148 s390/index 150 149 sh/index
-10
Documentation/input/conf.py
··· 1 - # -*- coding: utf-8; mode: python -*- 2 - 3 - project = "The Linux input driver subsystem" 4 - 5 - tags.add("subproject") 6 - 7 - latex_documents = [ 8 - ('index', 'linux-input.tex', project, 9 - 'The kernel development community', 'manual'), 10 - ]
-10
Documentation/kernel-hacking/conf.py
··· 1 - # -*- coding: utf-8; mode: python -*- 2 - 3 - project = "Kernel Hacking Guides" 4 - 5 - tags.add("subproject") 6 - 7 - latex_documents = [ 8 - ('index', 'kernel-hacking.tex', project, 9 - 'The kernel development community', 'manual'), 10 - ]
+2 -2
Documentation/locking/spinlocks.rst
··· 82 82 **changes** the list will have to get the write lock. 83 83 84 84 NOTE! RCU is better for list traversal, but requires careful 85 - attention to design detail (see Documentation/RCU/listRCU.txt). 85 + attention to design detail (see Documentation/RCU/listRCU.rst). 86 86 87 87 Also, you cannot "upgrade" a read-lock to a write-lock, so if you at _any_ 88 88 time need to do any changes (even if you don't do it every time), you have ··· 90 90 91 91 NOTE! We are working hard to remove reader-writer spinlocks in most 92 92 cases, so please don't add a new one without consensus. (Instead, see 93 - Documentation/RCU/rcu.txt for complete information.) 93 + Documentation/RCU/rcu.rst for complete information.) 94 94 95 95 ---- 96 96
-10
Documentation/maintainer/conf.py
··· 1 - # -*- coding: utf-8; mode: python -*- 2 - 3 - project = 'Linux Kernel Development Documentation' 4 - 5 - tags.add("subproject") 6 - 7 - latex_documents = [ 8 - ('index', 'maintainer.tex', 'Linux Kernel Development Documentation', 9 - 'The kernel development community', 'manual'), 10 - ]
-12
Documentation/media/conf.py
··· 1 - # -*- coding: utf-8; mode: python -*- 2 - 3 - # SPDX-License-Identifier: GPL-2.0 4 - 5 - project = 'Linux Media Subsystem Documentation' 6 - 7 - tags.add("subproject") 8 - 9 - latex_documents = [ 10 - ('index', 'media.tex', 'Linux Media Subsystem Documentation', 11 - 'The kernel development community', 'manual'), 12 - ]
+1 -1
Documentation/memory-barriers.txt
··· 548 548 549 549 [*] For information on bus mastering DMA and coherency please read: 550 550 551 - Documentation/PCI/pci.rst 551 + Documentation/driver-api/pci/pci.rst 552 552 Documentation/DMA-API-HOWTO.txt 553 553 Documentation/DMA-API.txt 554 554
-10
Documentation/networking/conf.py
··· 1 - # -*- coding: utf-8; mode: python -*- 2 - 3 - project = "Linux Networking Documentation" 4 - 5 - tags.add("subproject") 6 - 7 - latex_documents = [ 8 - ('index', 'networking.tex', project, 9 - 'The kernel development community', 'manual'), 10 - ]
+1 -1
Documentation/power/index.rst
··· 1 - :orphan: 1 + .. SPDX-License-Identifier: GPL-2.0 2 2 3 3 ================ 4 4 Power Management
+9 -6
Documentation/powerpc/DAWR-POWER9.txt Documentation/powerpc/dawr-power9.rst
··· 1 + ===================== 1 2 DAWR issues on POWER9 2 - ============================ 3 + ===================== 3 4 4 5 On POWER9 the Data Address Watchpoint Register (DAWR) can cause a checkstop 5 6 if it points to cache inhibited (CI) memory. Currently Linux has no way to 6 7 disinguish CI memory when configuring the DAWR, so (for now) the DAWR is 7 - disabled by this commit: 8 + disabled by this commit:: 8 9 9 10 commit 9654153158d3e0684a1bdb76dbababdb7111d5a0 10 11 Author: Michael Neuling <mikey@neuling.org> ··· 13 12 powerpc: Disable DAWR in the base POWER9 CPU features 14 13 15 14 Technical Details: 16 - ============================ 15 + ================== 17 16 18 17 DAWR has 6 different ways of being set. 19 18 1) ptrace ··· 38 37 For xmon, the 'bd' command will return an error on P9. 39 38 40 39 Consequences for users 41 - ============================ 40 + ====================== 42 41 43 42 For GDB watchpoints (ie 'watch' command) on POWER9 bare metal , GDB 44 43 will accept the command. Unfortunately since there is no hardware ··· 58 57 migrated back to the POWER8 host, it will start working again. 59 58 60 59 Force enabling the DAWR 61 - ============================= 62 - Kernels (since ~v5.2) have an option to force enable the DAWR via: 60 + ======================= 61 + Kernels (since ~v5.2) have an option to force enable the DAWR via:: 63 62 64 63 echo Y > /sys/kernel/debug/powerpc/dawr_enable_dangerous 65 64 ··· 87 86 writing the DAWR. 88 87 89 88 To double check the DAWR is working, run this kernel selftest: 89 + 90 90 tools/testing/selftests/powerpc/ptrace/ptrace-hwbreak.c 91 + 91 92 Any errors/failures/skips mean something is wrong.
+21 -7
Documentation/powerpc/bootwrapper.txt Documentation/powerpc/bootwrapper.rst
··· 1 + ======================== 1 2 The PowerPC boot wrapper 2 - ------------------------ 3 + ======================== 4 + 3 5 Copyright (C) Secret Lab Technologies Ltd. 4 6 5 7 PowerPC image targets compresses and wraps the kernel image (vmlinux) with ··· 23 21 image. The details of the build system is discussed in the next section. 24 22 Currently, the following image format targets exist: 25 23 24 + ==================== ======================================================== 26 25 cuImage.%: Backwards compatible uImage for older version of 27 26 U-Boot (for versions that don't understand the device 28 27 tree). This image embeds a device tree blob inside ··· 32 29 with boot wrapper code that extracts data from the old 33 30 bd_info structure and loads the data into the device 34 31 tree before jumping into the kernel. 35 - Because of the series of #ifdefs found in the 32 + 33 + Because of the series of #ifdefs found in the 36 34 bd_info structure used in the old U-Boot interfaces, 37 35 cuImages are platform specific. Each specific 38 36 U-Boot platform has a different platform init file 39 37 which populates the embedded device tree with data 40 38 from the platform specific bd_info file. The platform 41 39 specific cuImage platform init code can be found in 42 - arch/powerpc/boot/cuboot.*.c. Selection of the correct 40 + `arch/powerpc/boot/cuboot.*.c`. Selection of the correct 43 41 cuImage init code for a specific board can be found in 44 42 the wrapper structure. 43 + 45 44 dtbImage.%: Similar to zImage, except device tree blob is embedded 46 45 inside the image instead of provided by firmware. The 47 46 output image file can be either an elf file or a flat 48 47 binary depending on the platform. 49 - dtbImages are used on systems which do not have an 48 + 49 + dtbImages are used on systems which do not have an 50 50 interface for passing a device tree directly. 51 51 dtbImages are similar to simpleImages except that 52 52 dtbImages have platform specific code for extracting 53 53 data from the board firmware, but simpleImages do not 54 54 talk to the firmware at all. 55 - PlayStation 3 support uses dtbImage. So do Embedded 55 + 56 + PlayStation 3 support uses dtbImage. So do Embedded 56 57 Planet boards using the PlanetCore firmware. Board 57 58 specific initialization code is typically found in a 58 59 file named arch/powerpc/boot/<platform>.c; but this 59 60 can be overridden by the wrapper script. 61 + 60 62 simpleImage.%: Firmware independent compressed image that does not 61 63 depend on any particular firmware interface and embeds 62 64 a device tree blob. This image is a flat binary that ··· 69 61 Firmware cannot pass any configuration data to the 70 62 kernel with this image type and it depends entirely on 71 63 the embedded device tree for all information. 72 - The simpleImage is useful for booting systems with 64 + 65 + The simpleImage is useful for booting systems with 73 66 an unknown firmware interface or for booting from 74 67 a debugger when no firmware is present (such as on 75 68 the Xilinx Virtex platform). The only assumption that 76 69 simpleImage makes is that RAM is correctly initialized 77 70 and that the MMU is either off or has RAM mapped to 78 71 base address 0. 79 - simpleImage also supports inserting special platform 72 + 73 + simpleImage also supports inserting special platform 80 74 specific initialization code to the start of the bootup 81 75 sequence. The virtex405 platform uses this feature to 82 76 ensure that the cache is invalidated before caching ··· 91 81 named (virtex405-<board>.dts). Search the wrapper 92 82 script for 'virtex405' and see the file 93 83 arch/powerpc/boot/virtex405-head.S for details. 84 + 94 85 treeImage.%; Image format for used with OpenBIOS firmware found 95 86 on some ppc4xx hardware. This image embeds a device 96 87 tree blob inside the image. 88 + 97 89 uImage: Native image format used by U-Boot. The uImage target 98 90 does not add any boot code. It just wraps a compressed 99 91 vmlinux in the uImage data structure. This image ··· 103 91 a device tree to the kernel at boot. If using an older 104 92 version of U-Boot, then you need to use a cuImage 105 93 instead. 94 + 106 95 zImage.%: Image format which does not embed a device tree. 107 96 Used by OpenFirmware and other firmware interfaces 108 97 which are able to supply a device tree. This image 109 98 expects firmware to provide the device tree at boot. 110 99 Typically, if you have general purpose PowerPC 111 100 hardware then you want this image format. 101 + ==================== ======================================================== 112 102 113 103 Image types which embed a device tree blob (simpleImage, dtbImage, treeImage, 114 104 and cuImage) all generate the device tree blob from a file in the
+12 -11
Documentation/powerpc/cpu_families.txt Documentation/powerpc/cpu_families.rst
··· 1 + ============ 1 2 CPU Families 2 3 ============ 3 4 ··· 9 8 Book3S (aka sPAPR) 10 9 ------------------ 11 10 12 - - Hash MMU 13 - - Mix of 32 & 64 bit 11 + - Hash MMU 12 + - Mix of 32 & 64 bit:: 14 13 15 14 +--------------+ +----------------+ 16 15 | Old POWER | --------------> | RS64 (threads) | ··· 109 108 IBM BookE 110 109 --------- 111 110 112 - - Software loaded TLB. 113 - - All 32 bit 111 + - Software loaded TLB. 112 + - All 32 bit:: 114 113 115 114 +--------------+ 116 115 | 401 | ··· 156 155 Motorola/Freescale 8xx 157 156 ---------------------- 158 157 159 - - Software loaded with hardware assist. 160 - - All 32 bit 158 + - Software loaded with hardware assist. 159 + - All 32 bit:: 161 160 162 161 +-------------+ 163 162 | MPC8xx Core | ··· 167 166 Freescale BookE 168 167 --------------- 169 168 170 - - Software loaded TLB. 171 - - e6500 adds HW loaded indirect TLB entries. 172 - - Mix of 32 & 64 bit 169 + - Software loaded TLB. 170 + - e6500 adds HW loaded indirect TLB entries. 171 + - Mix of 32 & 64 bit:: 173 172 174 173 +--------------+ 175 174 | e200 | ··· 208 207 IBM A2 core 209 208 ----------- 210 209 211 - - Book3E, software loaded TLB + HW loaded indirect TLB entries. 212 - - 64 bit 210 + - Book3E, software loaded TLB + HW loaded indirect TLB entries. 211 + - 64 bit:: 213 212 214 213 +--------------+ +----------------+ 215 214 | A2 core | --> | WSP |
+5 -1
Documentation/powerpc/cpu_features.txt Documentation/powerpc/cpu_features.rst
··· 1 + ============ 2 + CPU Features 3 + ============ 4 + 1 5 Hollis Blanchard <hollis@austin.ibm.com> 2 6 5 Jun 2002 3 7 ··· 36 32 After detecting the processor type, the kernel patches out sections of code 37 33 that shouldn't be used by writing nop's over it. Using cpufeatures requires 38 34 just 2 macros (found in arch/powerpc/include/asm/cputable.h), as seen in head.S 39 - transfer_to_handler: 35 + transfer_to_handler:: 40 36 41 37 #ifdef CONFIG_ALTIVEC 42 38 BEGIN_FTR_SECTION
+32 -14
Documentation/powerpc/cxl.txt Documentation/powerpc/cxl.rst
··· 1 + ==================================== 1 2 Coherent Accelerator Interface (CXL) 2 3 ==================================== 3 4 ··· 21 20 22 21 Hardware overview 23 22 ================= 23 + 24 + :: 24 25 25 26 POWER8/9 FPGA 26 27 +----------+ +---------+ ··· 62 59 the fault. The context to which this fault is serviced is based on 63 60 who owns that acceleration function. 64 61 65 - POWER8 <-----> PSL Version 8 is compliant to the CAIA Version 1.0. 66 - POWER9 <-----> PSL Version 9 is compliant to the CAIA Version 2.0. 62 + - POWER8 and PSL Version 8 are compliant to the CAIA Version 1.0. 63 + - POWER9 and PSL Version 9 are compliant to the CAIA Version 2.0. 64 + 67 65 This PSL Version 9 provides new features such as: 66 + 68 67 * Interaction with the nest MMU on the P9 chip. 69 68 * Native DMA support. 70 69 * Supports sending ASB_Notify messages for host thread wakeup. 71 70 * Supports Atomic operations. 72 - * .... 71 + * etc. 73 72 74 73 Cards with a PSL9 won't work on a POWER8 system and cards with a 75 74 PSL8 won't work on a POWER9 system. ··· 152 147 master devices. 153 148 154 149 A userspace library libcxl is available here: 150 + 155 151 https://github.com/ibm-capi/libcxl 152 + 156 153 This provides a C interface to this kernel API. 157 154 158 155 open ··· 172 165 When all available contexts are allocated the open call will fail 173 166 and return -ENOSPC. 174 167 175 - Note: IRQs need to be allocated for each context, which may limit 168 + Note: 169 + IRQs need to be allocated for each context, which may limit 176 170 the number of contexts that can be created, and therefore 177 171 how many times the device can be opened. The POWER8 CAPP 178 172 supports 2040 IRQs and 3 are used by the kernel, so 2037 are ··· 194 186 updated as userspace allocates and frees memory. This ioctl 195 187 returns once the AFU context is started. 196 188 197 - Takes a pointer to a struct cxl_ioctl_start_work: 189 + Takes a pointer to a struct cxl_ioctl_start_work 190 + 191 + :: 198 192 199 193 struct cxl_ioctl_start_work { 200 194 __u64 flags; ··· 279 269 The buffer passed to read() must be at least 4K bytes. 280 270 281 271 The result of the read will be a buffer of one or more events, 282 - each event is of type struct cxl_event, of varying size. 272 + each event is of type struct cxl_event, of varying size:: 283 273 284 274 struct cxl_event { 285 275 struct cxl_event_header header; ··· 290 280 }; 291 281 }; 292 282 293 - The struct cxl_event_header is defined as: 283 + The struct cxl_event_header is defined as 284 + 285 + :: 294 286 295 287 struct cxl_event_header { 296 288 __u16 type; ··· 319 307 For future extensions and padding. 320 308 321 309 If the event type is CXL_EVENT_AFU_INTERRUPT then the event 322 - structure is defined as: 310 + structure is defined as 311 + 312 + :: 323 313 324 314 struct cxl_event_afu_interrupt { 325 315 __u16 flags; ··· 340 326 For future extensions and padding. 341 327 342 328 If the event type is CXL_EVENT_DATA_STORAGE then the event 343 - structure is defined as: 329 + structure is defined as 330 + 331 + :: 344 332 345 333 struct cxl_event_data_storage { 346 334 __u16 flags; ··· 372 356 For future extensions 373 357 374 358 If the event type is CXL_EVENT_AFU_ERROR then the event structure 375 - is defined as: 359 + is defined as 360 + 361 + :: 376 362 377 363 struct cxl_event_afu_error { 378 364 __u16 flags; ··· 411 393 ioctl 412 394 ----- 413 395 414 - CXL_IOCTL_DOWNLOAD_IMAGE: 415 - CXL_IOCTL_VALIDATE_IMAGE: 396 + CXL_IOCTL_DOWNLOAD_IMAGE / CXL_IOCTL_VALIDATE_IMAGE: 416 397 Starts and controls flashing a new FPGA image. Partial 417 398 reconfiguration is not supported (yet), so the image must contain 418 399 a copy of the PSL and AFU(s). Since an image can be quite large, 419 400 the caller may have to iterate, splitting the image in smaller 420 401 chunks. 421 402 422 - Takes a pointer to a struct cxl_adapter_image: 403 + Takes a pointer to a struct cxl_adapter_image:: 404 + 423 405 struct cxl_adapter_image { 424 406 __u64 flags; 425 407 __u64 data; ··· 460 442 The following udev rules could be used to create a symlink to the 461 443 most logical chardev to use in any programming mode (afuX.Yd for 462 444 dedicated, afuX.Ys for afu directed), since the API is virtually 463 - identical for each: 445 + identical for each:: 464 446 465 447 SUBSYSTEM=="cxl", ATTRS{mode}=="dedicated_process", SYMLINK="cxl/%b" 466 448 SUBSYSTEM=="cxl", ATTRS{mode}=="afu_directed", \
+7 -3
Documentation/powerpc/cxlflash.txt Documentation/powerpc/cxlflash.rst
··· 1 + ================================ 2 + Coherent Accelerator (CXL) Flash 3 + ================================ 4 + 1 5 Introduction 2 6 ============ 3 7 ··· 32 28 responsible for the initialization of the adapter, setting up the 33 29 special path for user space access, and performing error recovery. It 34 30 communicates directly the Flash Accelerator Functional Unit (AFU) 35 - as described in Documentation/powerpc/cxl.txt. 31 + as described in Documentation/powerpc/cxl.rst. 36 32 37 33 The cxlflash driver supports two, mutually exclusive, modes of 38 34 operation at the device (LUN) level: ··· 62 58 63 59 The CXL Flash Adapter Driver establishes a master context with the 64 60 AFU. It uses memory mapped I/O (MMIO) for this control and setup. The 65 - Adapter Problem Space Memory Map looks like this: 61 + Adapter Problem Space Memory Map looks like this:: 66 62 67 63 +-------------------------------+ 68 64 | 512 * 64 KB User MMIO | ··· 379 375 Each host adapter instance that is supported by the cxlflash driver 380 376 has a special character device associated with it to enable a set of 381 377 host management function. These character devices are hosted in a 382 - class dedicated for cxlflash and can be accessed via /dev/cxlflash/*. 378 + class dedicated for cxlflash and can be accessed via `/dev/cxlflash/*`. 383 379 384 380 Applications can be written to perform various functions using the 385 381 host ioctl APIs below.
+11 -7
Documentation/powerpc/dscr.txt Documentation/powerpc/dscr.rst
··· 1 - DSCR (Data Stream Control Register) 2 - ================================================ 1 + =================================== 2 + DSCR (Data Stream Control Register) 3 + =================================== 3 4 4 5 DSCR register in powerpc allows user to have some control of prefetch of data 5 6 stream in the processor. Please refer to the ISA documents or related manual ··· 11 10 12 11 (A) Data Structures: 13 12 14 - (1) thread_struct: 13 + (1) thread_struct:: 14 + 15 15 dscr /* Thread DSCR value */ 16 16 dscr_inherit /* Thread has changed default DSCR */ 17 17 18 - (2) PACA: 18 + (2) PACA:: 19 + 19 20 dscr_default /* per-CPU DSCR default value */ 20 21 21 - (3) sysfs.c: 22 + (3) sysfs.c:: 23 + 22 24 dscr_default /* System DSCR default value */ 23 25 24 26 (B) Scheduler Changes: ··· 39 35 40 36 (C) SYSFS Interface: 41 37 42 - Global DSCR default: /sys/devices/system/cpu/dscr_default 43 - CPU specific DSCR default: /sys/devices/system/cpu/cpuN/dscr 38 + - Global DSCR default: /sys/devices/system/cpu/dscr_default 39 + - CPU specific DSCR default: /sys/devices/system/cpu/cpuN/dscr 44 40 45 41 Changing the global DSCR default in the sysfs will change all the CPU 46 42 specific DSCR defaults immediately in their PACA structures. Again if
+56 -54
Documentation/powerpc/eeh-pci-error-recovery.txt Documentation/powerpc/eeh-pci-error-recovery.rst
··· 1 + ========================== 2 + PCI Bus EEH Error Recovery 3 + ========================== 1 4 5 + Linas Vepstas <linas@austin.ibm.com> 2 6 3 - PCI Bus EEH Error Recovery 4 - -------------------------- 5 - Linas Vepstas 6 - <linas@austin.ibm.com> 7 - 12 January 2005 7 + 12 January 2005 8 8 9 9 10 10 Overview: ··· 143 143 all of these occur during boot, when the PCI bus is scanned, where 144 144 a large number of 0xff reads are part of the bus scan procedure. 145 145 146 - If a frozen slot is detected, code in 147 - arch/powerpc/platforms/pseries/eeh.c will print a stack trace to 148 - syslog (/var/log/messages). This stack trace has proven to be very 149 - useful to device-driver authors for finding out at what point the EEH 150 - error was detected, as the error itself usually occurs slightly 146 + If a frozen slot is detected, code in 147 + arch/powerpc/platforms/pseries/eeh.c will print a stack trace to 148 + syslog (/var/log/messages). This stack trace has proven to be very 149 + useful to device-driver authors for finding out at what point the EEH 150 + error was detected, as the error itself usually occurs slightly 151 151 beforehand. 152 152 153 153 Next, it uses the Linux kernel notifier chain/work queue mechanism to 154 154 allow any interested parties to find out about the failure. Device 155 155 drivers, or other parts of the kernel, can use 156 - eeh_register_notifier(struct notifier_block *) to find out about EEH 156 + `eeh_register_notifier(struct notifier_block *)` to find out about EEH 157 157 events. The event will include a pointer to the pci device, the 158 158 device node and some state info. Receivers of the event can "do as 159 159 they wish"; the default handler will be described further in this ··· 162 162 To assist in the recovery of the device, eeh.c exports the 163 163 following functions: 164 164 165 - rtas_set_slot_reset() -- assert the PCI #RST line for 1/8th of a second 166 - rtas_configure_bridge() -- ask firmware to configure any PCI bridges 165 + rtas_set_slot_reset() 166 + assert the PCI #RST line for 1/8th of a second 167 + rtas_configure_bridge() 168 + ask firmware to configure any PCI bridges 167 169 located topologically under the pci slot. 168 - eeh_save_bars() and eeh_restore_bars(): save and restore the PCI 170 + eeh_save_bars() and eeh_restore_bars(): 171 + save and restore the PCI 169 172 config-space info for a device and any devices under it. 170 173 171 174 ··· 194 191 195 192 Following is an example sequence of events that cause a device driver 196 193 close function to be called during the first phase of an EEH reset. 197 - The following sequence is an example of the pcnet32 device driver. 194 + The following sequence is an example of the pcnet32 device driver:: 198 195 199 196 rpa_php_unconfig_pci_adapter (struct slot *) // in rpaphp_pci.c 200 197 { ··· 244 241 }}}}}} 245 242 246 243 247 - in drivers/pci/pci_driver.c, 248 - struct device_driver->remove() is just pci_device_remove() 249 - which calls struct pci_driver->remove() which is pcnet32_remove_one() 250 - which calls unregister_netdev() (in net/core/dev.c) 251 - which calls dev_close() (in net/core/dev.c) 252 - which calls dev->stop() which is pcnet32_close() 253 - which then does the appropriate shutdown. 244 + in drivers/pci/pci_driver.c, 245 + struct device_driver->remove() is just pci_device_remove() 246 + which calls struct pci_driver->remove() which is pcnet32_remove_one() 247 + which calls unregister_netdev() (in net/core/dev.c) 248 + which calls dev_close() (in net/core/dev.c) 249 + which calls dev->stop() which is pcnet32_close() 250 + which then does the appropriate shutdown. 254 251 255 252 --- 256 - Following is the analogous stack trace for events sent to user-space 257 - when the pci device is unconfigured. 258 253 259 - rpa_php_unconfig_pci_adapter() { // in rpaphp_pci.c 260 - calls 261 - pci_remove_bus_device (struct pci_dev *) { // in /drivers/pci/remove.c 254 + Following is the analogous stack trace for events sent to user-space 255 + when the pci device is unconfigured:: 256 + 257 + rpa_php_unconfig_pci_adapter() { // in rpaphp_pci.c 262 258 calls 263 - pci_destroy_dev (struct pci_dev *) { 259 + pci_remove_bus_device (struct pci_dev *) { // in /drivers/pci/remove.c 264 260 calls 265 - device_unregister (&dev->dev) { // in /drivers/base/core.c 261 + pci_destroy_dev (struct pci_dev *) { 266 262 calls 267 - device_del(struct device * dev) { // in /drivers/base/core.c 263 + device_unregister (&dev->dev) { // in /drivers/base/core.c 268 264 calls 269 - kobject_del() { //in /libs/kobject.c 265 + device_del(struct device * dev) { // in /drivers/base/core.c 270 266 calls 271 - kobject_uevent() { // in /libs/kobject.c 267 + kobject_del() { //in /libs/kobject.c 272 268 calls 273 - kset_uevent() { // in /lib/kobject.c 269 + kobject_uevent() { // in /libs/kobject.c 274 270 calls 275 - kset->uevent_ops->uevent() // which is really just 276 - a call to 277 - dev_uevent() { // in /drivers/base/core.c 271 + kset_uevent() { // in /lib/kobject.c 278 272 calls 279 - dev->bus->uevent() which is really just a call to 280 - pci_uevent () { // in drivers/pci/hotplug.c 281 - which prints device name, etc.... 273 + kset->uevent_ops->uevent() // which is really just 274 + a call to 275 + dev_uevent() { // in /drivers/base/core.c 276 + calls 277 + dev->bus->uevent() which is really just a call to 278 + pci_uevent () { // in drivers/pci/hotplug.c 279 + which prints device name, etc.... 280 + } 282 281 } 283 - } 284 - then kobject_uevent() sends a netlink uevent to userspace 285 - --> userspace uevent 286 - (during early boot, nobody listens to netlink events and 287 - kobject_uevent() executes uevent_helper[], which runs the 288 - event process /sbin/hotplug) 282 + then kobject_uevent() sends a netlink uevent to userspace 283 + --> userspace uevent 284 + (during early boot, nobody listens to netlink events and 285 + kobject_uevent() executes uevent_helper[], which runs the 286 + event process /sbin/hotplug) 287 + } 289 288 } 290 - } 291 - kobject_del() then calls sysfs_remove_dir(), which would 292 - trigger any user-space daemon that was watching /sysfs, 293 - and notice the delete event. 289 + kobject_del() then calls sysfs_remove_dir(), which would 290 + trigger any user-space daemon that was watching /sysfs, 291 + and notice the delete event. 294 292 295 293 296 294 Pro's and Con's of the Current Design ··· 303 299 The biggest negative of the design is that it potentially disturbs 304 300 network daemons and file systems that didn't need to be disturbed. 305 301 306 - -- A minor complaint is that resetting the network card causes 302 + - A minor complaint is that resetting the network card causes 307 303 user-space back-to-back ifdown/ifup burps that potentially disturb 308 304 network daemons, that didn't need to even know that the pci 309 305 card was being rebooted. 310 306 311 - -- A more serious concern is that the same reset, for SCSI devices, 307 + - A more serious concern is that the same reset, for SCSI devices, 312 308 causes havoc to mounted file systems. Scripts cannot post-facto 313 309 unmount a file system without flushing pending buffers, but this 314 310 is impossible, because I/O has already been stopped. Thus, ··· 326 322 from the block layer. It would be very natural to add an EEH 327 323 reset into this chain of events. 328 324 329 - -- If a SCSI error occurs for the root device, all is lost unless 325 + - If a SCSI error occurs for the root device, all is lost unless 330 326 the sysadmin had the foresight to run /bin, /sbin, /etc, /var 331 327 and so on, out of ramdisk/tmpfs. 332 328 ··· 334 330 Conclusions 335 331 ----------- 336 332 There's forward progress ... 337 - 338 -
+63 -54
Documentation/powerpc/firmware-assisted-dump.txt Documentation/powerpc/firmware-assisted-dump.rst
··· 1 + ====================== 2 + Firmware-Assisted Dump 3 + ====================== 1 4 2 - Firmware-Assisted Dump 3 - ------------------------ 4 - July 2011 5 + July 2011 5 6 6 7 The goal of firmware-assisted dump is to enable the dump of 7 8 a crashed system, and to do so from a fully-reset system, and ··· 28 27 Comparing with kdump or other strategies, firmware-assisted 29 28 dump offers several strong, practical advantages: 30 29 31 - -- Unlike kdump, the system has been reset, and loaded 30 + - Unlike kdump, the system has been reset, and loaded 32 31 with a fresh copy of the kernel. In particular, 33 32 PCI and I/O devices have been reinitialized and are 34 33 in a clean, consistent state. 35 - -- Once the dump is copied out, the memory that held the dump 34 + - Once the dump is copied out, the memory that held the dump 36 35 is immediately available to the running kernel. And therefore, 37 36 unlike kdump, fadump doesn't need a 2nd reboot to get back 38 37 the system to the production configuration. ··· 41 40 and assistance from the Power firmware. The procedure is 42 41 as follows: 43 42 44 - -- The first kernel registers the sections of memory with the 43 + - The first kernel registers the sections of memory with the 45 44 Power firmware for dump preservation during OS initialization. 46 45 These registered sections of memory are reserved by the first 47 46 kernel during early boot. 48 47 49 - -- When a system crashes, the Power firmware will save 48 + - When a system crashes, the Power firmware will save 50 49 the low memory (boot memory of size larger of 5% of system RAM 51 50 or 256MB) of RAM to the previous registered region. It will 52 51 also save system registers, and hardware PTE's. 53 52 54 - NOTE: The term 'boot memory' means size of the low memory chunk 53 + NOTE: 54 + The term 'boot memory' means size of the low memory chunk 55 55 that is required for a kernel to boot successfully when 56 56 booted with restricted memory. By default, the boot memory 57 57 size will be the larger of 5% of system RAM or 256MB. ··· 66 64 as fadump uses a predefined offset to reserve memory 67 65 for boot memory dump preservation in case of a crash. 68 66 69 - -- After the low memory (boot memory) area has been saved, the 67 + - After the low memory (boot memory) area has been saved, the 70 68 firmware will reset PCI and other hardware state. It will 71 69 *not* clear the RAM. It will then launch the bootloader, as 72 70 normal. 73 71 74 - -- The freshly booted kernel will notice that there is a new 72 + - The freshly booted kernel will notice that there is a new 75 73 node (ibm,dump-kernel) in the device tree, indicating that 76 74 there is crash data available from a previous boot. During 77 75 the early boot OS will reserve rest of the memory above ··· 79 77 size. This will make sure that the second kernel will not 80 78 touch any of the dump memory area. 81 79 82 - -- User-space tools will read /proc/vmcore to obtain the contents 80 + - User-space tools will read /proc/vmcore to obtain the contents 83 81 of memory, which holds the previous crashed kernel dump in ELF 84 82 format. The userspace tools may copy this info to disk, or 85 83 network, nas, san, iscsi, etc. as desired. 86 84 87 - -- Once the userspace tool is done saving dump, it will echo 85 + - Once the userspace tool is done saving dump, it will echo 88 86 '1' to /sys/kernel/fadump_release_mem to release the reserved 89 87 memory back to general use, except the memory required for 90 88 next firmware-assisted dump registration. 91 89 92 - e.g. 90 + e.g.:: 91 + 93 92 # echo 1 > /sys/kernel/fadump_release_mem 94 93 95 94 Please note that the firmware-assisted dump feature ··· 98 95 firmware versions. 99 96 100 97 Implementation details: 101 - ---------------------- 98 + ----------------------- 102 99 103 100 During boot, a check is made to see if firmware supports 104 101 this feature on that particular machine. If it does, then ··· 124 121 With CMA reservation this memory will be available for applications to 125 122 use it, while kernel is prevented from using it. With this fadump will 126 123 still be able to capture all of the kernel memory and most of the user 127 - space memory except the user pages that were present in CMA region. 124 + space memory except the user pages that were present in CMA region:: 128 125 129 126 o Memory Reservation during first kernel 130 127 ··· 169 166 used for kdump. 170 167 171 168 How to enable firmware-assisted dump (fadump): 172 - ------------------------------------- 169 + ---------------------------------------------- 173 170 174 171 1. Set config option CONFIG_FA_DUMP=y and build kernel. 175 172 2. Boot into linux kernel with 'fadump=on' kernel cmdline option. ··· 180 177 to specify size of the memory to reserve for boot memory dump 181 178 preservation. 182 179 183 - NOTE: 1. 'fadump_reserve_mem=' parameter has been deprecated. Instead 184 - use 'crashkernel=' to specify size of the memory to reserve 185 - for boot memory dump preservation. 186 - 2. If firmware-assisted dump fails to reserve memory then it 187 - will fallback to existing kdump mechanism if 'crashkernel=' 188 - option is set at kernel cmdline. 189 - 3. if user wants to capture all of user space memory and ok with 190 - reserved memory not available to production system, then 191 - 'fadump=nocma' kernel parameter can be used to fallback to 192 - old behaviour. 180 + NOTE: 181 + 1. 'fadump_reserve_mem=' parameter has been deprecated. Instead 182 + use 'crashkernel=' to specify size of the memory to reserve 183 + for boot memory dump preservation. 184 + 2. If firmware-assisted dump fails to reserve memory then it 185 + will fallback to existing kdump mechanism if 'crashkernel=' 186 + option is set at kernel cmdline. 187 + 3. if user wants to capture all of user space memory and ok with 188 + reserved memory not available to production system, then 189 + 'fadump=nocma' kernel parameter can be used to fallback to 190 + old behaviour. 193 191 194 192 Sysfs/debugfs files: 195 - ------------ 193 + -------------------- 196 194 197 195 Firmware-assisted dump feature uses sysfs file system to hold 198 196 the control files and debugfs file to display memory reserved region. ··· 201 197 Here is the list of files under kernel sysfs: 202 198 203 199 /sys/kernel/fadump_enabled 204 - 205 200 This is used to display the fadump status. 206 - 0 = fadump is disabled 207 - 1 = fadump is enabled 201 + 202 + - 0 = fadump is disabled 203 + - 1 = fadump is enabled 208 204 209 205 This interface can be used by kdump init scripts to identify if 210 206 fadump is enabled in the kernel and act accordingly. 211 207 212 208 /sys/kernel/fadump_registered 213 - 214 209 This is used to display the fadump registration status as well 215 210 as to control (start/stop) the fadump registration. 216 - 0 = fadump is not registered. 217 - 1 = fadump is registered and ready to handle system crash. 211 + 212 + - 0 = fadump is not registered. 213 + - 1 = fadump is registered and ready to handle system crash. 218 214 219 215 To register fadump echo 1 > /sys/kernel/fadump_registered and 220 216 echo 0 > /sys/kernel/fadump_registered for un-register and stop the ··· 223 219 easily integrated with kdump service start/stop. 224 220 225 221 /sys/kernel/fadump_release_mem 226 - 227 222 This file is available only when fadump is active during 228 223 second kernel. This is used to release the reserved memory 229 224 region that are held for saving crash dump. To release the 230 - reserved memory echo 1 to it: 225 + reserved memory echo 1 to it:: 231 226 232 - echo 1 > /sys/kernel/fadump_release_mem 227 + echo 1 > /sys/kernel/fadump_release_mem 233 228 234 229 After echo 1, the content of the /sys/kernel/debug/powerpc/fadump_region 235 230 file will change to reflect the new memory reservations. ··· 241 238 (Assuming debugfs is mounted on /sys/kernel/debug directory.) 242 239 243 240 /sys/kernel/debug/powerpc/fadump_region 244 - 245 241 This file shows the reserved memory regions if fadump is 246 242 enabled otherwise this file is empty. The output format 247 - is: 248 - <region>: [<start>-<end>] <reserved-size> bytes, Dumped: <dump-size> 243 + is:: 244 + 245 + <region>: [<start>-<end>] <reserved-size> bytes, Dumped: <dump-size> 249 246 250 247 e.g. 251 - Contents when fadump is registered during first kernel 248 + Contents when fadump is registered during first kernel:: 252 249 253 - # cat /sys/kernel/debug/powerpc/fadump_region 254 - CPU : [0x0000006ffb0000-0x0000006fff001f] 0x40020 bytes, Dumped: 0x0 255 - HPTE: [0x0000006fff0020-0x0000006fff101f] 0x1000 bytes, Dumped: 0x0 256 - DUMP: [0x0000006fff1020-0x0000007fff101f] 0x10000000 bytes, Dumped: 0x0 250 + # cat /sys/kernel/debug/powerpc/fadump_region 251 + CPU : [0x0000006ffb0000-0x0000006fff001f] 0x40020 bytes, Dumped: 0x0 252 + HPTE: [0x0000006fff0020-0x0000006fff101f] 0x1000 bytes, Dumped: 0x0 253 + DUMP: [0x0000006fff1020-0x0000007fff101f] 0x10000000 bytes, Dumped: 0x0 257 254 258 - Contents when fadump is active during second kernel 255 + Contents when fadump is active during second kernel:: 259 256 260 - # cat /sys/kernel/debug/powerpc/fadump_region 261 - CPU : [0x0000006ffb0000-0x0000006fff001f] 0x40020 bytes, Dumped: 0x40020 262 - HPTE: [0x0000006fff0020-0x0000006fff101f] 0x1000 bytes, Dumped: 0x1000 263 - DUMP: [0x0000006fff1020-0x0000007fff101f] 0x10000000 bytes, Dumped: 0x10000000 264 - : [0x00000010000000-0x0000006ffaffff] 0x5ffb0000 bytes, Dumped: 0x5ffb0000 257 + # cat /sys/kernel/debug/powerpc/fadump_region 258 + CPU : [0x0000006ffb0000-0x0000006fff001f] 0x40020 bytes, Dumped: 0x40020 259 + HPTE: [0x0000006fff0020-0x0000006fff101f] 0x1000 bytes, Dumped: 0x1000 260 + DUMP: [0x0000006fff1020-0x0000007fff101f] 0x10000000 bytes, Dumped: 0x10000000 261 + : [0x00000010000000-0x0000006ffaffff] 0x5ffb0000 bytes, Dumped: 0x5ffb0000 265 262 266 - NOTE: Please refer to Documentation/filesystems/debugfs.txt on 263 + NOTE: 264 + Please refer to Documentation/filesystems/debugfs.txt on 267 265 how to mount the debugfs filesystem. 268 266 269 267 270 268 TODO: 271 269 ----- 272 - o Need to come up with the better approach to find out more 270 + - Need to come up with the better approach to find out more 273 271 accurate boot memory size that is required for a kernel to 274 272 boot successfully when booted with restricted memory. 275 - o The fadump implementation introduces a fadump crash info structure 273 + - The fadump implementation introduces a fadump crash info structure 276 274 in the scratch area before the ELF core header. The idea of introducing 277 275 this structure is to pass some important crash info data to the second 278 276 kernel which will help second kernel to populate ELF core header with ··· 281 277 design implementation does not address a possibility of introducing 282 278 additional fields (in future) to this structure without affecting 283 279 compatibility. Need to come up with the better approach to address this. 280 + 284 281 The possible approaches are: 282 + 285 283 1. Introduce version field for version tracking, bump up the version 286 284 whenever a new field is added to the structure in future. The version 287 285 field can be used to find out what fields are valid for the current ··· 291 285 2. Reserve the area of predefined size (say PAGE_SIZE) for this 292 286 structure and have unused area as reserved (initialized to zero) 293 287 for future field additions. 288 + 294 289 The advantage of approach 1 over 2 is we don't need to reserve extra space. 295 - --- 290 + 296 291 Author: Mahesh Salgaonkar <mahesh@linux.vnet.ibm.com> 292 + 297 293 This document is based on the original documentation written for phyp 294 + 298 295 assisted dump by Linas Vepstas and Manish Ahuja.
+61 -47
Documentation/powerpc/hvcs.txt Documentation/powerpc/hvcs.rst
··· 1 - =========================================================================== 2 - HVCS 3 - IBM "Hypervisor Virtual Console Server" Installation Guide 4 - for Linux Kernel 2.6.4+ 5 - Copyright (C) 2004 IBM Corporation 1 + =============================================================== 2 + HVCS IBM "Hypervisor Virtual Console Server" Installation Guide 3 + =============================================================== 6 4 7 - =========================================================================== 8 - NOTE:Eight space tabs are the optimum editor setting for reading this file. 9 - =========================================================================== 5 + for Linux Kernel 2.6.4+ 10 6 11 - Author(s) : Ryan S. Arnold <rsa@us.ibm.com> 12 - Date Created: March, 02, 2004 13 - Last Changed: August, 24, 2004 7 + Copyright (C) 2004 IBM Corporation 14 8 15 - --------------------------------------------------------------------------- 16 - Table of contents: 9 + .. =========================================================================== 10 + .. NOTE:Eight space tabs are the optimum editor setting for reading this file. 11 + .. =========================================================================== 12 + 13 + 14 + Author(s): Ryan S. Arnold <rsa@us.ibm.com> 15 + 16 + Date Created: March, 02, 2004 17 + Last Changed: August, 24, 2004 18 + 19 + .. Table of contents: 17 20 18 21 1. Driver Introduction: 19 22 2. System Requirements ··· 30 27 8. Questions & Answers: 31 28 9. Reporting Bugs: 32 29 33 - --------------------------------------------------------------------------- 34 30 1. Driver Introduction: 31 + ======================= 35 32 36 33 This is the device driver for the IBM Hypervisor Virtual Console Server, 37 34 "hvcs". The IBM hvcs provides a tty driver interface to allow Linux user ··· 41 38 on this hardware so system consoles are accessed by this driver using 42 39 firmware interfaces to virtual terminal devices. 43 40 44 - --------------------------------------------------------------------------- 45 41 2. System Requirements: 42 + ======================= 46 43 47 44 This device driver was written using 2.6.4 Linux kernel APIs and will only 48 45 build and run on kernels of this version or later. ··· 55 52 major and minor numbers are associated with each vty-server. Directions 56 53 for sysfs mounting are outside the scope of this document. 57 54 58 - --------------------------------------------------------------------------- 59 55 3. Build Options: 56 + ================= 60 57 61 58 The hvcs driver registers itself as a tty driver. The tty layer 62 59 dynamically allocates a block of major and minor numbers in a quantity ··· 68 65 built into the kernel. If not, the default can be over-ridden by inserting 69 66 the driver as a module with insmod parameters. 70 67 71 - --------------------------------------------------------------------------- 72 68 3.1 Built-in: 69 + ------------- 73 70 74 71 The following menuconfig example demonstrates selecting to build this 75 - driver into the kernel. 72 + driver into the kernel:: 76 73 77 74 Device Drivers ---> 78 75 Character devices ---> ··· 80 77 81 78 Begin the kernel make process. 82 79 83 - --------------------------------------------------------------------------- 84 80 3.2 Module: 81 + ----------- 85 82 86 83 The following menuconfig example demonstrates selecting to build this 87 - driver as a kernel module. 84 + driver as a kernel module:: 88 85 89 86 Device Drivers ---> 90 87 Character devices ---> ··· 92 89 93 90 The make process will build the following kernel modules: 94 91 95 - hvcs.ko 96 - hvcserver.ko 92 + - hvcs.ko 93 + - hvcserver.ko 97 94 98 95 To insert the module with the default allocation execute the following 99 - commands in the order they appear: 96 + commands in the order they appear:: 100 97 101 98 insmod hvcserver.ko 102 99 insmod hvcs.ko ··· 106 103 symbols it expects. 107 104 108 105 To override the default use an insmod parameter as follows (requesting 4 109 - tty devices as an example): 106 + tty devices as an example):: 110 107 111 108 insmod hvcs.ko hvcs_parm_num_devs=4 112 109 ··· 118 115 NOTE: The length of time it takes to insmod the driver seems to be related 119 116 to the number of tty interfaces the registering driver requests. 120 117 121 - In order to remove the driver module execute the following command: 118 + In order to remove the driver module execute the following command:: 122 119 123 120 rmmod hvcs.ko 124 121 125 122 The recommended method for installing hvcs as a module is to use depmod to 126 123 build a current modules.dep file in /lib/modules/`uname -r` and then 127 - execute: 124 + execute:: 128 125 129 - modprobe hvcs hvcs_parm_num_devs=4 126 + modprobe hvcs hvcs_parm_num_devs=4 130 127 131 128 The modules.dep file indicates that hvcserver.ko needs to be inserted 132 129 before hvcs.ko and modprobe uses this file to smartly insert the modules in 133 130 the proper order. 134 131 135 132 The following modprobe command is used to remove hvcs and hvcserver in the 136 - proper order: 133 + proper order:: 137 134 138 - modprobe -r hvcs 135 + modprobe -r hvcs 139 136 140 - --------------------------------------------------------------------------- 141 137 4. Installation: 138 + ================ 142 139 143 140 The tty layer creates sysfs entries which contain the major and minor 144 141 numbers allocated for the hvcs driver. The following snippet of "tree" 145 - output of the sysfs directory shows where these numbers are presented: 142 + output of the sysfs directory shows where these numbers are presented:: 146 143 147 144 sys/ 148 145 |-- *other sysfs base dirs* ··· 167 164 |-- *other sysfs base dirs* 168 165 169 166 For the above examples the following output is a result of cat'ing the 170 - "dev" entry in the hvcs directory: 167 + "dev" entry in the hvcs directory:: 171 168 172 169 Pow5:/sys/class/tty/hvcs0/ # cat dev 173 170 254:0 ··· 187 184 will do it automatically. 188 185 189 186 Given the example output above, to manually create a /dev/hvcs* node entry 190 - mknod can be used as follows: 187 + mknod can be used as follows:: 191 188 192 189 mknod /dev/hvcs0 c 254 0 193 190 mknod /dev/hvcs1 c 254 1 ··· 198 195 persistent. Once created they will exist prior to the driver insmod. 199 196 200 197 Attempting to connect an application to /dev/hvcs* prior to insertion of 201 - the hvcs module will result in an error message similar to the following: 198 + the hvcs module will result in an error message similar to the following:: 202 199 203 200 "/dev/hvcs*: No such device". 204 201 205 202 NOTE: Just because there is a device node present doesn't mean that there 206 203 is a vty-server device configured for that node. 207 204 208 - --------------------------------------------------------------------------- 209 205 5. Connection 206 + ============= 210 207 211 208 Since this driver controls devices that provide a tty interface a user can 212 209 interact with the device node entries using any standard tty-interactive ··· 252 249 attribute has been added to each vty-server sysfs entry. This entry is 253 250 called "index" and showing it reveals an integer that refers to the 254 251 /dev/hvcs* entry to use to connect to that device. For instance cating the 255 - index attribute of vty-server adapter 30000004 shows the following. 252 + index attribute of vty-server adapter 30000004 shows the following:: 256 253 257 254 Pow5:/sys/bus/vio/drivers/hvcs/30000004 # cat index 258 255 2 ··· 265 262 adapter is not guaranteed to remain the same across system reboots. Look 266 263 in the Q & A section for more on this issue. 267 264 268 - --------------------------------------------------------------------------- 269 265 6. Disconnection 266 + ================ 270 267 271 268 As a security feature to prevent the delivery of stale data to an 272 269 unintended target the Power5 system firmware disables the fetching of data ··· 308 305 previously read '1'. The write directive is ignored if the vterm_state 309 306 read '0' or if any value other than '0' was written to the vterm_state 310 307 attribute. The following example will show the method used for verifying 311 - the vty-server connection status and disconnecting a vty-server connection. 308 + the vty-server connection status and disconnecting a vty-server connection:: 312 309 313 310 Pow5:/sys/bus/vio/drivers/hvcs/30000004 # cat vterm_state 314 311 1 ··· 321 318 All vty-server connections are automatically terminated when the device is 322 319 hotplug removed and when the module is removed. 323 320 324 - --------------------------------------------------------------------------- 325 321 7. Configuration 322 + ================ 326 323 327 324 Each vty-server has a sysfs entry in the /sys/devices/vio directory, which 328 325 is symlinked in several other sysfs tree directories, notably under the 329 - hvcs driver entry, which looks like the following example: 326 + hvcs driver entry, which looks like the following example:: 330 327 331 328 Pow5:/sys/bus/vio/drivers/hvcs # ls 332 329 . .. 30000003 30000004 rescan ··· 347 344 348 345 Vty-server entries in this directory are a 32 bit partition unique unit 349 346 address that is created by firmware. An example vty-server sysfs entry 350 - looks like the following: 347 + looks like the following:: 351 348 352 349 Pow5:/sys/bus/vio/drivers/hvcs/30000004 # ls 353 350 . current_vty devspec name partner_vtys ··· 355 352 356 353 Each entry is provided, by default with a "name" attribute. Reading the 357 354 "name" attribute will reveal the device type as shown in the following 358 - example: 355 + example:: 359 356 360 357 Pow5:/sys/bus/vio/drivers/hvcs/30000003 # cat name 361 358 vty-server 362 359 363 360 Each entry is also provided, by default, with a "devspec" attribute which 364 361 reveals the full device specification when read, as shown in the following 365 - example: 362 + example:: 366 363 367 364 Pow5:/sys/bus/vio/drivers/hvcs/30000004 # cat devspec 368 365 /vdevice/vty-server@30000004 369 366 370 367 Each vty-server sysfs dir is provided with two read-only attributes that 371 368 provide lists of easily parsed partner vty data: "partner_vtys" and 372 - "partner_clcs". 369 + "partner_clcs":: 373 370 374 371 Pow5:/sys/bus/vio/drivers/hvcs/30000004 # cat partner_vtys 375 372 30000000 ··· 399 396 read. 400 397 401 398 The current_vty can be changed by writing a valid partner clc to the entry 402 - as in the following example: 399 + as in the following example:: 403 400 404 401 Pow5:/sys/bus/vio/drivers/hvcs/30000004 # echo U5112.428.10304 405 402 8A-V4-C0 > current_vty ··· 411 408 Information on the "vterm_state" attribute was covered earlier on the 412 409 chapter entitled "disconnection". 413 410 414 - --------------------------------------------------------------------------- 415 411 8. Questions & Answers: 416 - =========================================================================== 412 + ======================= 413 + 417 414 Q: What are the security concerns involving hvcs? 418 415 419 416 A: There are three main security concerns: ··· 432 429 partition) will experience the previously logged in session. 433 430 434 431 --------------------------------------------------------------------------- 432 + 435 433 Q: How do I multiplex a console that I grab through hvcs so that other 436 434 people can see it: 437 435 ··· 444 440 not display properly in screen sessions. 445 441 446 442 --------------------------------------------------------------------------- 443 + 447 444 Q: Why are the colors all messed up? 448 445 Q: Why are the control characters acting strange or not working? 449 446 Q: Why is the console output all strange and unintelligible? ··· 460 455 their own TERM type set when they login. 461 456 462 457 --------------------------------------------------------------------------- 458 + 463 459 Q: When I try to CONNECT kermit to an hvcs device I get: 464 460 "Sorry, can't open connection: /dev/hvcs*"What is happening? 465 461 ··· 496 490 /dev/hvcs* entry. 497 491 498 492 --------------------------------------------------------------------------- 493 + 499 494 Q: When I try to CONNECT kermit to an hvcs device I get: 500 495 "Sorry, write access to UUCP lockfile directory denied." 501 496 ··· 504 497 does? Maybe you haven't inserted the module (on systems with udev). 505 498 506 499 --------------------------------------------------------------------------- 500 + 507 501 Q: If I already have one Linux partition installed can I use hvcs on said 508 502 partition to provide the console for the install of a second Linux 509 503 partition? ··· 513 505 kermit or cu or some other program that doesn't provide terminal emulation. 514 506 515 507 --------------------------------------------------------------------------- 508 + 516 509 Q: Can I connect to more than one partition's console at a time using this 517 510 driver? 518 511 ··· 521 512 configured for this partition and each must point to a disconnected vty. 522 513 523 514 --------------------------------------------------------------------------- 515 + 524 516 Q: Does the hvcs driver support dynamic (hotplug) addition of devices? 525 517 526 518 A: Yes, if you have dlpar and hotplug enabled for your system and it has ··· 529 519 handle additions of new devices and removals of unused devices. 530 520 531 521 --------------------------------------------------------------------------- 522 + 532 523 Q: For some reason /dev/hvcs* doesn't map to the same vty-server adapter 533 524 after a reboot. What happened? 534 525 ··· 544 533 Hint; look at the sysfs "index" attribute for the vty-server. 545 534 546 535 --------------------------------------------------------------------------- 536 + 547 537 Q: Can I use /dev/hvcs* as a conduit to another partition and use a tty 548 538 device on that partition as the other end of the pipe? 549 539 ··· 566 554 partitions. 567 555 568 556 --------------------------------------------------------------------------- 557 + 569 558 9. Reporting Bugs: 559 + ================== 570 560 571 561 The proper channel for reporting bugs is either through the Linux OS 572 562 distribution company that provided your OS or by posting issues to the
+34
Documentation/powerpc/index.rst
··· 1 + .. SPDX-License-Identifier: GPL-2.0 2 + 3 + ======= 4 + powerpc 5 + ======= 6 + 7 + .. toctree:: 8 + :maxdepth: 1 9 + 10 + bootwrapper 11 + cpu_families 12 + cpu_features 13 + cxl 14 + cxlflash 15 + dawr-power9 16 + dscr 17 + eeh-pci-error-recovery 18 + firmware-assisted-dump 19 + hvcs 20 + isa-versions 21 + mpc52xx 22 + pci_iov_resource_on_powernv 23 + pmu-ebb 24 + ptrace 25 + qe_firmware 26 + syscall64-abi 27 + transactional_memory 28 + 29 + .. only:: subproject and html 30 + 31 + Indices 32 + ======= 33 + 34 + * :ref:`genindex`
+7 -8
Documentation/powerpc/isa-versions.rst
··· 1 - :orphan: 2 - 1 + ========================== 3 2 CPU to ISA Version Mapping 4 3 ========================== 5 4 6 5 Mapping of some CPU versions to relevant ISA versions. 7 6 8 - ========= ==================== 7 + ========= ==================================================================== 9 8 CPU Architecture version 10 - ========= ==================== 9 + ========= ==================================================================== 11 10 Power9 Power ISA v3.0B 12 11 Power8 Power ISA v2.07 13 12 Power7 Power ISA v2.06 ··· 23 24 - PowerPC Virtual Environment Architecture Book II v2.01 24 25 - PowerPC Operating Environment Architecture Book III v2.01 25 26 - Plus Altivec/VMX ~= 2.03 26 - ========= ==================== 27 + ========= ==================================================================== 27 28 28 29 29 30 Key Features ··· 59 60 PPC970 No 60 61 ========== ==== 61 62 62 - ========== ==================== 63 + ========== ==================================== 63 64 CPU Transactional Memory 64 - ========== ==================== 65 + ========== ==================================== 65 66 Power9 Yes (* see transactional_memory.txt) 66 67 Power8 Yes 67 68 Power7 No ··· 72 73 Power5+ No 73 74 Power5 No 74 75 PPC970 No 75 - ========== ==================== 76 + ========== ====================================
+8 -4
Documentation/powerpc/mpc52xx.txt Documentation/powerpc/mpc52xx.rst
··· 1 + ============================= 1 2 Linux 2.6.x on MPC52xx family 2 - ----------------------------- 3 + ============================= 3 4 4 5 For the latest info, go to http://www.246tNt.com/mpc52xx/ 5 6 6 7 To compile/use : 7 8 8 - - U-Boot: 9 + - U-Boot:: 10 + 9 11 # <edit Makefile to set ARCH=ppc & CROSS_COMPILE=... ( also EXTRAVERSION 10 12 if you wish to ). 11 13 # make lite5200_defconfig ··· 18 16 => tftpboot 400000 pRamdisk 19 17 => bootm 200000 400000 20 18 21 - - DBug: 19 + - DBug:: 20 + 22 21 # <edit Makefile to set ARCH=ppc & CROSS_COMPILE=... ( also EXTRAVERSION 23 22 if you wish to ). 24 23 # make lite5200_defconfig ··· 31 28 DBug> dn -i zImage.initrd.lite5200 32 29 33 30 34 - Some remarks : 31 + Some remarks: 32 + 35 33 - The port is named mpc52xxx, and config options are PPC_MPC52xx. The MGT5100 36 34 is not supported, and I'm not sure anyone is interesting in working on it 37 35 so. I didn't took 5xxx because there's apparently a lot of 5xxx that have
+13 -2
Documentation/powerpc/pci_iov_resource_on_powernv.txt Documentation/powerpc/pci_iov_resource_on_powernv.rst
··· 1 + =================================================== 2 + PCI Express I/O Virtualization Resource on Powerenv 3 + =================================================== 4 + 1 5 Wei Yang <weiyang@linux.vnet.ibm.com> 6 + 2 7 Benjamin Herrenschmidt <benh@au1.ibm.com> 8 + 3 9 Bjorn Helgaas <bhelgaas@google.com> 10 + 4 11 26 Aug 2014 5 12 6 13 This document describes the requirement from hardware for PCI MMIO resource ··· 17 10 about considerations on enabling SRIOV on IODA2. 18 11 19 12 1. Introduction to Partitionable Endpoints 13 + ========================================== 20 14 21 15 A Partitionable Endpoint (PE) is a way to group the various resources 22 16 associated with a device or a set of devices to provide isolation between ··· 43 35 its own set of PEs, etc. 44 36 45 37 2. Implementation of Partitionable Endpoints on P8 (IODA2) 38 + ========================================================== 46 39 47 40 P8 supports up to 256 Partitionable Endpoints per PHB. 48 41 ··· 158 149 sense, but we haven't done it yet. 159 150 160 151 3. Considerations for SR-IOV on PowerKVM 152 + ======================================== 161 153 162 154 * SR-IOV Background 163 155 ··· 234 224 IODA supports 256 PEs, so segmented windows contain 256 segments, so if 235 225 total_VFs is less than 256, we have the situation in Figure 1.0, where 236 226 segments [total_VFs, 255] of the M64 window may map to some MMIO range on 237 - other devices: 227 + other devices:: 238 228 239 229 0 1 total_VFs - 1 240 230 +------+------+- -+------+------+ ··· 253 243 Figure 1.0 Direct map VF(n) BAR space 254 244 255 245 Our current solution is to allocate 256 segments even if the VF(n) BAR 256 - space doesn't need that much, as shown in Figure 1.1: 246 + space doesn't need that much, as shown in Figure 1.1:: 257 247 258 248 0 1 total_VFs - 1 255 259 249 +------+------+- -+------+------+- -+------+------+ ··· 279 269 responds to segments [total_VFs, 255]. 280 270 281 271 4. Implications for the Generic PCI Code 272 + ======================================== 282 273 283 274 The PCIe SR-IOV spec requires that the base of the VF(n) BAR space be 284 275 aligned to the size of an individual VF BAR.
+1
Documentation/powerpc/pmu-ebb.txt Documentation/powerpc/pmu-ebb.rst
··· 1 + ======================== 1 2 PMU Event Based Branches 2 3 ======================== 3 4
+156
Documentation/powerpc/ptrace.rst
··· 1 + ====== 2 + Ptrace 3 + ====== 4 + 5 + GDB intends to support the following hardware debug features of BookE 6 + processors: 7 + 8 + 4 hardware breakpoints (IAC) 9 + 2 hardware watchpoints (read, write and read-write) (DAC) 10 + 2 value conditions for the hardware watchpoints (DVC) 11 + 12 + For that, we need to extend ptrace so that GDB can query and set these 13 + resources. Since we're extending, we're trying to create an interface 14 + that's extendable and that covers both BookE and server processors, so 15 + that GDB doesn't need to special-case each of them. We added the 16 + following 3 new ptrace requests. 17 + 18 + 1. PTRACE_PPC_GETHWDEBUGINFO 19 + ============================ 20 + 21 + Query for GDB to discover the hardware debug features. The main info to 22 + be returned here is the minimum alignment for the hardware watchpoints. 23 + BookE processors don't have restrictions here, but server processors have 24 + an 8-byte alignment restriction for hardware watchpoints. We'd like to avoid 25 + adding special cases to GDB based on what it sees in AUXV. 26 + 27 + Since we're at it, we added other useful info that the kernel can return to 28 + GDB: this query will return the number of hardware breakpoints, hardware 29 + watchpoints and whether it supports a range of addresses and a condition. 30 + The query will fill the following structure provided by the requesting process:: 31 + 32 + struct ppc_debug_info { 33 + unit32_t version; 34 + unit32_t num_instruction_bps; 35 + unit32_t num_data_bps; 36 + unit32_t num_condition_regs; 37 + unit32_t data_bp_alignment; 38 + unit32_t sizeof_condition; /* size of the DVC register */ 39 + uint64_t features; /* bitmask of the individual flags */ 40 + }; 41 + 42 + features will have bits indicating whether there is support for:: 43 + 44 + #define PPC_DEBUG_FEATURE_INSN_BP_RANGE 0x1 45 + #define PPC_DEBUG_FEATURE_INSN_BP_MASK 0x2 46 + #define PPC_DEBUG_FEATURE_DATA_BP_RANGE 0x4 47 + #define PPC_DEBUG_FEATURE_DATA_BP_MASK 0x8 48 + #define PPC_DEBUG_FEATURE_DATA_BP_DAWR 0x10 49 + 50 + 2. PTRACE_SETHWDEBUG 51 + 52 + Sets a hardware breakpoint or watchpoint, according to the provided structure:: 53 + 54 + struct ppc_hw_breakpoint { 55 + uint32_t version; 56 + #define PPC_BREAKPOINT_TRIGGER_EXECUTE 0x1 57 + #define PPC_BREAKPOINT_TRIGGER_READ 0x2 58 + #define PPC_BREAKPOINT_TRIGGER_WRITE 0x4 59 + uint32_t trigger_type; /* only some combinations allowed */ 60 + #define PPC_BREAKPOINT_MODE_EXACT 0x0 61 + #define PPC_BREAKPOINT_MODE_RANGE_INCLUSIVE 0x1 62 + #define PPC_BREAKPOINT_MODE_RANGE_EXCLUSIVE 0x2 63 + #define PPC_BREAKPOINT_MODE_MASK 0x3 64 + uint32_t addr_mode; /* address match mode */ 65 + 66 + #define PPC_BREAKPOINT_CONDITION_MODE 0x3 67 + #define PPC_BREAKPOINT_CONDITION_NONE 0x0 68 + #define PPC_BREAKPOINT_CONDITION_AND 0x1 69 + #define PPC_BREAKPOINT_CONDITION_EXACT 0x1 /* different name for the same thing as above */ 70 + #define PPC_BREAKPOINT_CONDITION_OR 0x2 71 + #define PPC_BREAKPOINT_CONDITION_AND_OR 0x3 72 + #define PPC_BREAKPOINT_CONDITION_BE_ALL 0x00ff0000 /* byte enable bits */ 73 + #define PPC_BREAKPOINT_CONDITION_BE(n) (1<<((n)+16)) 74 + uint32_t condition_mode; /* break/watchpoint condition flags */ 75 + 76 + uint64_t addr; 77 + uint64_t addr2; 78 + uint64_t condition_value; 79 + }; 80 + 81 + A request specifies one event, not necessarily just one register to be set. 82 + For instance, if the request is for a watchpoint with a condition, both the 83 + DAC and DVC registers will be set in the same request. 84 + 85 + With this GDB can ask for all kinds of hardware breakpoints and watchpoints 86 + that the BookE supports. COMEFROM breakpoints available in server processors 87 + are not contemplated, but that is out of the scope of this work. 88 + 89 + ptrace will return an integer (handle) uniquely identifying the breakpoint or 90 + watchpoint just created. This integer will be used in the PTRACE_DELHWDEBUG 91 + request to ask for its removal. Return -ENOSPC if the requested breakpoint 92 + can't be allocated on the registers. 93 + 94 + Some examples of using the structure to: 95 + 96 + - set a breakpoint in the first breakpoint register:: 97 + 98 + p.version = PPC_DEBUG_CURRENT_VERSION; 99 + p.trigger_type = PPC_BREAKPOINT_TRIGGER_EXECUTE; 100 + p.addr_mode = PPC_BREAKPOINT_MODE_EXACT; 101 + p.condition_mode = PPC_BREAKPOINT_CONDITION_NONE; 102 + p.addr = (uint64_t) address; 103 + p.addr2 = 0; 104 + p.condition_value = 0; 105 + 106 + - set a watchpoint which triggers on reads in the second watchpoint register:: 107 + 108 + p.version = PPC_DEBUG_CURRENT_VERSION; 109 + p.trigger_type = PPC_BREAKPOINT_TRIGGER_READ; 110 + p.addr_mode = PPC_BREAKPOINT_MODE_EXACT; 111 + p.condition_mode = PPC_BREAKPOINT_CONDITION_NONE; 112 + p.addr = (uint64_t) address; 113 + p.addr2 = 0; 114 + p.condition_value = 0; 115 + 116 + - set a watchpoint which triggers only with a specific value:: 117 + 118 + p.version = PPC_DEBUG_CURRENT_VERSION; 119 + p.trigger_type = PPC_BREAKPOINT_TRIGGER_READ; 120 + p.addr_mode = PPC_BREAKPOINT_MODE_EXACT; 121 + p.condition_mode = PPC_BREAKPOINT_CONDITION_AND | PPC_BREAKPOINT_CONDITION_BE_ALL; 122 + p.addr = (uint64_t) address; 123 + p.addr2 = 0; 124 + p.condition_value = (uint64_t) condition; 125 + 126 + - set a ranged hardware breakpoint:: 127 + 128 + p.version = PPC_DEBUG_CURRENT_VERSION; 129 + p.trigger_type = PPC_BREAKPOINT_TRIGGER_EXECUTE; 130 + p.addr_mode = PPC_BREAKPOINT_MODE_RANGE_INCLUSIVE; 131 + p.condition_mode = PPC_BREAKPOINT_CONDITION_NONE; 132 + p.addr = (uint64_t) begin_range; 133 + p.addr2 = (uint64_t) end_range; 134 + p.condition_value = 0; 135 + 136 + - set a watchpoint in server processors (BookS):: 137 + 138 + p.version = 1; 139 + p.trigger_type = PPC_BREAKPOINT_TRIGGER_RW; 140 + p.addr_mode = PPC_BREAKPOINT_MODE_RANGE_INCLUSIVE; 141 + or 142 + p.addr_mode = PPC_BREAKPOINT_MODE_EXACT; 143 + 144 + p.condition_mode = PPC_BREAKPOINT_CONDITION_NONE; 145 + p.addr = (uint64_t) begin_range; 146 + /* For PPC_BREAKPOINT_MODE_RANGE_INCLUSIVE addr2 needs to be specified, where 147 + * addr2 - addr <= 8 Bytes. 148 + */ 149 + p.addr2 = (uint64_t) end_range; 150 + p.condition_value = 0; 151 + 152 + 3. PTRACE_DELHWDEBUG 153 + 154 + Takes an integer which identifies an existing breakpoint or watchpoint 155 + (i.e., the value returned from PTRACE_SETHWDEBUG), and deletes the 156 + corresponding breakpoint or watchpoint..
-151
Documentation/powerpc/ptrace.txt
··· 1 - GDB intends to support the following hardware debug features of BookE 2 - processors: 3 - 4 - 4 hardware breakpoints (IAC) 5 - 2 hardware watchpoints (read, write and read-write) (DAC) 6 - 2 value conditions for the hardware watchpoints (DVC) 7 - 8 - For that, we need to extend ptrace so that GDB can query and set these 9 - resources. Since we're extending, we're trying to create an interface 10 - that's extendable and that covers both BookE and server processors, so 11 - that GDB doesn't need to special-case each of them. We added the 12 - following 3 new ptrace requests. 13 - 14 - 1. PTRACE_PPC_GETHWDEBUGINFO 15 - 16 - Query for GDB to discover the hardware debug features. The main info to 17 - be returned here is the minimum alignment for the hardware watchpoints. 18 - BookE processors don't have restrictions here, but server processors have 19 - an 8-byte alignment restriction for hardware watchpoints. We'd like to avoid 20 - adding special cases to GDB based on what it sees in AUXV. 21 - 22 - Since we're at it, we added other useful info that the kernel can return to 23 - GDB: this query will return the number of hardware breakpoints, hardware 24 - watchpoints and whether it supports a range of addresses and a condition. 25 - The query will fill the following structure provided by the requesting process: 26 - 27 - struct ppc_debug_info { 28 - unit32_t version; 29 - unit32_t num_instruction_bps; 30 - unit32_t num_data_bps; 31 - unit32_t num_condition_regs; 32 - unit32_t data_bp_alignment; 33 - unit32_t sizeof_condition; /* size of the DVC register */ 34 - uint64_t features; /* bitmask of the individual flags */ 35 - }; 36 - 37 - features will have bits indicating whether there is support for: 38 - 39 - #define PPC_DEBUG_FEATURE_INSN_BP_RANGE 0x1 40 - #define PPC_DEBUG_FEATURE_INSN_BP_MASK 0x2 41 - #define PPC_DEBUG_FEATURE_DATA_BP_RANGE 0x4 42 - #define PPC_DEBUG_FEATURE_DATA_BP_MASK 0x8 43 - #define PPC_DEBUG_FEATURE_DATA_BP_DAWR 0x10 44 - 45 - 2. PTRACE_SETHWDEBUG 46 - 47 - Sets a hardware breakpoint or watchpoint, according to the provided structure: 48 - 49 - struct ppc_hw_breakpoint { 50 - uint32_t version; 51 - #define PPC_BREAKPOINT_TRIGGER_EXECUTE 0x1 52 - #define PPC_BREAKPOINT_TRIGGER_READ 0x2 53 - #define PPC_BREAKPOINT_TRIGGER_WRITE 0x4 54 - uint32_t trigger_type; /* only some combinations allowed */ 55 - #define PPC_BREAKPOINT_MODE_EXACT 0x0 56 - #define PPC_BREAKPOINT_MODE_RANGE_INCLUSIVE 0x1 57 - #define PPC_BREAKPOINT_MODE_RANGE_EXCLUSIVE 0x2 58 - #define PPC_BREAKPOINT_MODE_MASK 0x3 59 - uint32_t addr_mode; /* address match mode */ 60 - 61 - #define PPC_BREAKPOINT_CONDITION_MODE 0x3 62 - #define PPC_BREAKPOINT_CONDITION_NONE 0x0 63 - #define PPC_BREAKPOINT_CONDITION_AND 0x1 64 - #define PPC_BREAKPOINT_CONDITION_EXACT 0x1 /* different name for the same thing as above */ 65 - #define PPC_BREAKPOINT_CONDITION_OR 0x2 66 - #define PPC_BREAKPOINT_CONDITION_AND_OR 0x3 67 - #define PPC_BREAKPOINT_CONDITION_BE_ALL 0x00ff0000 /* byte enable bits */ 68 - #define PPC_BREAKPOINT_CONDITION_BE(n) (1<<((n)+16)) 69 - uint32_t condition_mode; /* break/watchpoint condition flags */ 70 - 71 - uint64_t addr; 72 - uint64_t addr2; 73 - uint64_t condition_value; 74 - }; 75 - 76 - A request specifies one event, not necessarily just one register to be set. 77 - For instance, if the request is for a watchpoint with a condition, both the 78 - DAC and DVC registers will be set in the same request. 79 - 80 - With this GDB can ask for all kinds of hardware breakpoints and watchpoints 81 - that the BookE supports. COMEFROM breakpoints available in server processors 82 - are not contemplated, but that is out of the scope of this work. 83 - 84 - ptrace will return an integer (handle) uniquely identifying the breakpoint or 85 - watchpoint just created. This integer will be used in the PTRACE_DELHWDEBUG 86 - request to ask for its removal. Return -ENOSPC if the requested breakpoint 87 - can't be allocated on the registers. 88 - 89 - Some examples of using the structure to: 90 - 91 - - set a breakpoint in the first breakpoint register 92 - 93 - p.version = PPC_DEBUG_CURRENT_VERSION; 94 - p.trigger_type = PPC_BREAKPOINT_TRIGGER_EXECUTE; 95 - p.addr_mode = PPC_BREAKPOINT_MODE_EXACT; 96 - p.condition_mode = PPC_BREAKPOINT_CONDITION_NONE; 97 - p.addr = (uint64_t) address; 98 - p.addr2 = 0; 99 - p.condition_value = 0; 100 - 101 - - set a watchpoint which triggers on reads in the second watchpoint register 102 - 103 - p.version = PPC_DEBUG_CURRENT_VERSION; 104 - p.trigger_type = PPC_BREAKPOINT_TRIGGER_READ; 105 - p.addr_mode = PPC_BREAKPOINT_MODE_EXACT; 106 - p.condition_mode = PPC_BREAKPOINT_CONDITION_NONE; 107 - p.addr = (uint64_t) address; 108 - p.addr2 = 0; 109 - p.condition_value = 0; 110 - 111 - - set a watchpoint which triggers only with a specific value 112 - 113 - p.version = PPC_DEBUG_CURRENT_VERSION; 114 - p.trigger_type = PPC_BREAKPOINT_TRIGGER_READ; 115 - p.addr_mode = PPC_BREAKPOINT_MODE_EXACT; 116 - p.condition_mode = PPC_BREAKPOINT_CONDITION_AND | PPC_BREAKPOINT_CONDITION_BE_ALL; 117 - p.addr = (uint64_t) address; 118 - p.addr2 = 0; 119 - p.condition_value = (uint64_t) condition; 120 - 121 - - set a ranged hardware breakpoint 122 - 123 - p.version = PPC_DEBUG_CURRENT_VERSION; 124 - p.trigger_type = PPC_BREAKPOINT_TRIGGER_EXECUTE; 125 - p.addr_mode = PPC_BREAKPOINT_MODE_RANGE_INCLUSIVE; 126 - p.condition_mode = PPC_BREAKPOINT_CONDITION_NONE; 127 - p.addr = (uint64_t) begin_range; 128 - p.addr2 = (uint64_t) end_range; 129 - p.condition_value = 0; 130 - 131 - - set a watchpoint in server processors (BookS) 132 - 133 - p.version = 1; 134 - p.trigger_type = PPC_BREAKPOINT_TRIGGER_RW; 135 - p.addr_mode = PPC_BREAKPOINT_MODE_RANGE_INCLUSIVE; 136 - or 137 - p.addr_mode = PPC_BREAKPOINT_MODE_EXACT; 138 - 139 - p.condition_mode = PPC_BREAKPOINT_CONDITION_NONE; 140 - p.addr = (uint64_t) begin_range; 141 - /* For PPC_BREAKPOINT_MODE_RANGE_INCLUSIVE addr2 needs to be specified, where 142 - * addr2 - addr <= 8 Bytes. 143 - */ 144 - p.addr2 = (uint64_t) end_range; 145 - p.condition_value = 0; 146 - 147 - 3. PTRACE_DELHWDEBUG 148 - 149 - Takes an integer which identifies an existing breakpoint or watchpoint 150 - (i.e., the value returned from PTRACE_SETHWDEBUG), and deletes the 151 - corresponding breakpoint or watchpoint..
+19 -18
Documentation/powerpc/qe_firmware.txt Documentation/powerpc/qe_firmware.rst
··· 1 - Freescale QUICC Engine Firmware Uploading 2 - ----------------------------------------- 1 + ========================================= 2 + Freescale QUICC Engine Firmware Uploading 3 + ========================================= 3 4 4 5 (c) 2007 Timur Tabi <timur at freescale.com>, 5 6 Freescale Semiconductor 6 7 7 - Table of Contents 8 - ================= 8 + .. Table of Contents 9 9 10 - I - Software License for Firmware 10 + I - Software License for Firmware 11 11 12 - II - Microcode Availability 12 + II - Microcode Availability 13 13 14 - III - Description and Terminology 14 + III - Description and Terminology 15 15 16 - IV - Microcode Programming Details 16 + IV - Microcode Programming Details 17 17 18 - V - Firmware Structure Layout 18 + V - Firmware Structure Layout 19 19 20 - VI - Sample Code for Creating Firmware Files 20 + VI - Sample Code for Creating Firmware Files 21 21 22 22 Revision Information 23 23 ==================== ··· 39 39 your Freescale representative or your operating system vendor. 40 40 41 41 III - Description and Terminology 42 - ================================ 42 + ================================= 43 43 44 44 In this document, the term 'microcode' refers to the sequence of 32-bit 45 45 integers that compose the actual QE microcode. ··· 89 89 structure signals the microcode which of these virtual traps is active. 90 90 91 91 This structure contains 6 words that the application should copy to some 92 - specific been defined. This table describes the structure. 92 + specific been defined. This table describes the structure:: 93 93 94 94 --------------------------------------------------------------- 95 95 | Offset in | | Destination Offset | Size of | ··· 119 119 This is a double word bit array (64 bits) that defines special functionality 120 120 which has an impact on the software drivers. Each bit has its own impact 121 121 and has special instructions for the s/w associated with it. This structure is 122 - described in this table: 122 + described in this table:: 123 123 124 124 ----------------------------------------------------------------------- 125 125 | Bit # | Name | Description | ··· 220 220 'major' and 'minor' fields are the major and minor revision numbers, 221 221 respectively, of the SOC. 222 222 223 - For example, to match the 8323, revision 1.0: 223 + For example, to match the 8323, revision 1.0:: 224 + 224 225 soc.model = 8323 225 226 soc.major = 1 226 227 soc.minor = 0 ··· 274 273 'reserved'. 275 274 276 275 After the last microcode is a 32-bit CRC. It can be calculated using 277 - this algorithm: 276 + this algorithm:: 278 277 279 - u32 crc32(const u8 *p, unsigned int len) 280 - { 278 + u32 crc32(const u8 *p, unsigned int len) 279 + { 281 280 unsigned int i; 282 281 u32 crc = 0; 283 282 ··· 287 286 crc = (crc >> 1) ^ ((crc & 1) ? 0xedb88320 : 0); 288 287 } 289 288 return crc; 290 - } 289 + } 291 290 292 291 VI - Sample Code for Creating Firmware Files 293 292 ============================================
+17 -12
Documentation/powerpc/syscall64-abi.txt Documentation/powerpc/syscall64-abi.rst
··· 5 5 syscall 6 6 ======= 7 7 8 - syscall calling sequence[*] matches the Power Architecture 64-bit ELF ABI 8 + syscall calling sequence\ [1]_ matches the Power Architecture 64-bit ELF ABI 9 9 specification C function calling sequence, including register preservation 10 10 rules, with the following differences. 11 11 12 - [*] Some syscalls (typically low-level management functions) may have 13 - different calling sequences (e.g., rt_sigreturn). 12 + .. [1] Some syscalls (typically low-level management functions) may have 13 + different calling sequences (e.g., rt_sigreturn). 14 14 15 15 Parameters and return value 16 16 --------------------------- ··· 33 33 Register preservation rules match the ELF ABI calling sequence with the 34 34 following differences: 35 35 36 - r0: Volatile. (System call number.) 37 - r3: Volatile. (Parameter 1, and return value.) 38 - r4-r8: Volatile. (Parameters 2-6.) 39 - cr0: Volatile (cr0.SO is the return error condition) 40 - cr1, cr5-7: Nonvolatile. 41 - lr: Nonvolatile. 36 + =========== ============= ======================================== 37 + r0 Volatile (System call number.) 38 + r3 Volatile (Parameter 1, and return value.) 39 + r4-r8 Volatile (Parameters 2-6.) 40 + cr0 Volatile (cr0.SO is the return error condition) 41 + cr1, cr5-7 Nonvolatile 42 + lr Nonvolatile 43 + =========== ============= ======================================== 42 44 43 45 All floating point and vector data registers as well as control and status 44 46 registers are nonvolatile. ··· 92 90 93 91 Register preservation rules 94 92 --------------------------- 95 - r0: Volatile. 96 - cr1, cr5-7: Volatile. 97 - lr: Volatile. 93 + 94 + =========== ======== 95 + r0 Volatile 96 + cr1, cr5-7 Volatile 97 + lr Volatile 98 + =========== ======== 98 99 99 100 Invocation 100 101 ----------
+24 -21
Documentation/powerpc/transactional_memory.txt Documentation/powerpc/transactional_memory.rst
··· 1 + ============================ 1 2 Transactional Memory support 2 3 ============================ 3 4 ··· 18 17 guaranteed to either complete atomically or roll back and undo any partial 19 18 changes. 20 19 21 - A simple transaction looks like this: 20 + A simple transaction looks like this:: 22 21 23 - begin_move_money: 24 - tbegin 25 - beq abort_handler 22 + begin_move_money: 23 + tbegin 24 + beq abort_handler 26 25 27 - ld r4, SAVINGS_ACCT(r3) 28 - ld r5, CURRENT_ACCT(r3) 29 - subi r5, r5, 1 30 - addi r4, r4, 1 31 - std r4, SAVINGS_ACCT(r3) 32 - std r5, CURRENT_ACCT(r3) 26 + ld r4, SAVINGS_ACCT(r3) 27 + ld r5, CURRENT_ACCT(r3) 28 + subi r5, r5, 1 29 + addi r4, r4, 1 30 + std r4, SAVINGS_ACCT(r3) 31 + std r5, CURRENT_ACCT(r3) 33 32 34 - tend 33 + tend 35 34 36 - b continue 35 + b continue 37 36 38 - abort_handler: 39 - ... test for odd failures ... 37 + abort_handler: 38 + ... test for odd failures ... 40 39 41 - /* Retry the transaction if it failed because it conflicted with 42 - * someone else: */ 43 - b begin_move_money 40 + /* Retry the transaction if it failed because it conflicted with 41 + * someone else: */ 42 + b begin_move_money 44 43 45 44 46 45 The 'tbegin' instruction denotes the start point, and 'tend' the end point. ··· 124 123 from the second ucontext. This will be necessary for crash handlers to 125 124 determine, for example, the address of the instruction causing the SIGSEGV. 126 125 127 - Example signal handler: 126 + Example signal handler:: 128 127 129 128 void crash_handler(int sig, siginfo_t *si, void *uc) 130 129 { ··· 134 133 if (ucp_link) { 135 134 u64 msr = ucp->uc_mcontext.regs->msr; 136 135 /* May have transactional ucontext! */ 137 - #ifndef __powerpc64__ 136 + #ifndef __powerpc64__ 138 137 msr |= ((u64)transactional_ucp->uc_mcontext.regs->msr) << 32; 139 - #endif 138 + #endif 140 139 if (MSR_TM_ACTIVE(msr)) { 141 140 /* Yes, we crashed during a transaction. Oops. */ 142 141 fprintf(stderr, "Transaction to be restarted at 0x%llx, but " ··· 177 176 These are defined in <asm/reg.h>, and distinguish different reasons why the 178 177 kernel aborted a transaction: 179 178 179 + ====================== ================================ 180 180 TM_CAUSE_RESCHED Thread was rescheduled. 181 181 TM_CAUSE_TLBI Software TLB invalid. 182 182 TM_CAUSE_FAC_UNAV FP/VEC/VSX unavailable trap. ··· 186 184 TM_CAUSE_MISC Currently unused. 187 185 TM_CAUSE_ALIGNMENT Alignment fault. 188 186 TM_CAUSE_EMULATE Emulation that touched memory. 187 + ====================== ================================ 189 188 190 189 These can be checked by the user program's abort handler as TEXASR[0:7]. If 191 190 bit 7 is set, it indicates that the error is consider persistent. For example ··· 206 203 ====== 207 204 208 205 TM on POWER9 has issues with storing the complete register state. This 209 - is described in this commit: 206 + is described in this commit:: 210 207 211 208 commit 4bb3c7a0208fc13ca70598efd109901a7cd45ae7 212 209 Author: Paul Mackerras <paulus@ozlabs.org>
-10
Documentation/process/conf.py
··· 1 - # -*- coding: utf-8; mode: python -*- 2 - 3 - project = 'Linux Kernel Development Documentation' 4 - 5 - tags.add("subproject") 6 - 7 - latex_documents = [ 8 - ('index', 'process.tex', 'Linux Kernel Development Documentation', 9 - 'The kernel development community', 'manual'), 10 - ]
-10
Documentation/sh/conf.py
··· 1 - # -*- coding: utf-8; mode: python -*- 2 - 3 - project = "SuperH architecture implementation manual" 4 - 5 - tags.add("subproject") 6 - 7 - latex_documents = [ 8 - ('index', 'sh.tex', project, 9 - 'The kernel development community', 'manual'), 10 - ]
-10
Documentation/sound/conf.py
··· 1 - # -*- coding: utf-8; mode: python -*- 2 - 3 - project = "Linux Sound Subsystem Documentation" 4 - 5 - tags.add("subproject") 6 - 7 - latex_documents = [ 8 - ('index', 'sound.tex', project, 9 - 'The kernel development community', 'manual'), 10 - ]
+26 -1
Documentation/sphinx/load_config.py
··· 21 21 and os.path.normpath(namespace["__file__"]) != os.path.normpath(config_file) ): 22 22 config_file = os.path.abspath(config_file) 23 23 24 + # Let's avoid one conf.py file just due to latex_documents 25 + start = config_file.find('Documentation/') 26 + if start >= 0: 27 + start = config_file.find('/', start + 1) 28 + 29 + end = config_file.rfind('/') 30 + if start >= 0 and end > 0: 31 + dir = config_file[start + 1:end] 32 + 33 + print("source directory: %s" % dir) 34 + new_latex_docs = [] 35 + latex_documents = namespace['latex_documents'] 36 + 37 + for l in latex_documents: 38 + if l[0].find(dir + '/') == 0: 39 + has = True 40 + fn = l[0][len(dir) + 1:] 41 + new_latex_docs.append((fn, l[1], l[2], l[3], l[4])) 42 + break 43 + 44 + namespace['latex_documents'] = new_latex_docs 45 + 46 + # If there is an extra conf.py file, load it 24 47 if os.path.isfile(config_file): 25 48 sys.stdout.write("load additional sphinx-config: %s\n" % config_file) 26 49 config = namespace.copy() ··· 52 29 del config['__file__'] 53 30 namespace.update(config) 54 31 else: 55 - sys.stderr.write("WARNING: additional sphinx-config not found: %s\n" % config_file) 32 + config = namespace.copy() 33 + config['tags'].add("subproject") 34 + namespace.update(config)
+1 -1
Documentation/translations/ko_KR/memory-barriers.txt
··· 569 569 570 570 [*] 버스 마스터링 DMA 와 일관성에 대해서는 다음을 참고하시기 바랍니다: 571 571 572 - Documentation/PCI/pci.rst 572 + Documentation/driver-api/pci/pci.rst 573 573 Documentation/DMA-API-HOWTO.txt 574 574 Documentation/DMA-API.txt 575 575
-10
Documentation/userspace-api/conf.py
··· 1 - # -*- coding: utf-8; mode: python -*- 2 - 3 - project = "The Linux kernel user-space API guide" 4 - 5 - tags.add("subproject") 6 - 7 - latex_documents = [ 8 - ('index', 'userspace-api.tex', project, 9 - 'The kernel development community', 'manual'), 10 - ]
+1
Documentation/virtual/kvm/index.rst
··· 9 9 10 10 amd-memory-encryption 11 11 cpuid 12 + vcpu-requests
-10
Documentation/vm/conf.py
··· 1 - # -*- coding: utf-8; mode: python -*- 2 - 3 - project = "Linux Memory Management Documentation" 4 - 5 - tags.add("subproject") 6 - 7 - latex_documents = [ 8 - ('index', 'memory-management.tex', project, 9 - 'The kernel development community', 'manual'), 10 - ]
+1 -1
Documentation/watchdog/hpwdt.rst
··· 63 63 and loop forever. This is generally not what a watchdog user wants. 64 64 65 65 For those wishing to learn more please see: 66 - Documentation/kdump/kdump.rst 66 + Documentation/admin-guide/kdump/kdump.rst 67 67 Documentation/admin-guide/kernel-parameters.txt (panic=) 68 68 Your Linux Distribution specific documentation. 69 69
-10
Documentation/x86/conf.py
··· 1 - # -*- coding: utf-8; mode: python -*- 2 - 3 - project = "X86 architecture specific documentation" 4 - 5 - tags.add("subproject") 6 - 7 - latex_documents = [ 8 - ('index', 'x86.tex', project, 9 - 'The kernel development community', 'manual'), 10 - ]
+7 -7
MAINTAINERS
··· 899 899 W: http://ez.analog.com/community/linux-device-drivers 900 900 S: Supported 901 901 F: drivers/iio/adc/ad7124.c 902 - F: Documentation/devicetree/bindings/iio/adc/adi,ad7124.txt 902 + F: Documentation/devicetree/bindings/iio/adc/adi,ad7124.yaml 903 903 904 904 ANALOG DEVICES INC AD7606 DRIVER 905 905 M: Stefan Popa <stefan.popa@analog.com> ··· 4190 4190 L: cgroups@vger.kernel.org 4191 4191 L: linux-block@vger.kernel.org 4192 4192 T: git git://git.kernel.dk/linux-block 4193 - F: Documentation/cgroup-v1/blkio-controller.rst 4193 + F: Documentation/admin-guide/cgroup-v1/blkio-controller.rst 4194 4194 F: block/blk-cgroup.c 4195 4195 F: include/linux/blk-cgroup.h 4196 4196 F: block/blk-throttle.c ··· 4469 4469 F: drivers/misc/cxl/ 4470 4470 F: include/misc/cxl* 4471 4471 F: include/uapi/misc/cxl.h 4472 - F: Documentation/powerpc/cxl.txt 4472 + F: Documentation/powerpc/cxl.rst 4473 4473 F: Documentation/ABI/testing/sysfs-class-cxl 4474 4474 4475 4475 CXLFLASH (IBM Coherent Accelerator Processor Interface CAPI Flash) SCSI DRIVER ··· 4480 4480 S: Supported 4481 4481 F: drivers/scsi/cxlflash/ 4482 4482 F: include/uapi/scsi/cxlflash_ioctl.h 4483 - F: Documentation/powerpc/cxlflash.txt 4483 + F: Documentation/powerpc/cxlflash.rst 4484 4484 4485 4485 CYBERPRO FB DRIVER 4486 4486 M: Russell King <linux@armlinux.org.uk> ··· 6856 6856 R: Jon Olson <jonolson@google.com> 6857 6857 L: netdev@vger.kernel.org 6858 6858 S: Supported 6859 - F: Documentation/networking/device_drivers/google/gve.txt 6859 + F: Documentation/networking/device_drivers/google/gve.rst 6860 6860 F: drivers/net/ethernet/google 6861 6861 6862 6862 GPD POCKET FAN DRIVER ··· 12137 12137 M: "VMware, Inc." <pv-drivers@vmware.com> 12138 12138 L: virtualization@lists.linux-foundation.org 12139 12139 S: Supported 12140 - F: Documentation/virtual/paravirt_ops.txt 12140 + F: Documentation/virtual/paravirt_ops.rst 12141 12141 F: arch/*/kernel/paravirt* 12142 12142 F: arch/*/include/asm/paravirt*.h 12143 12143 F: include/linux/hypervisor.h ··· 12394 12394 F: drivers/pci/pcie/aer.c 12395 12395 F: drivers/pci/pcie/dpc.c 12396 12396 F: drivers/pci/pcie/err.c 12397 - F: Documentation/powerpc/eeh-pci-error-recovery.txt 12397 + F: Documentation/powerpc/eeh-pci-error-recovery.rst 12398 12398 F: arch/powerpc/kernel/eeh*.c 12399 12399 F: arch/powerpc/platforms/*/eeh*.c 12400 12400 F: arch/powerpc/include/*/eeh*.h
+1 -1
arch/powerpc/kernel/exceptions-64s.S
··· 1531 1531 * 1532 1532 * Call convention: 1533 1533 * 1534 - * syscall register convention is in Documentation/powerpc/syscall64-abi.txt 1534 + * syscall register convention is in Documentation/powerpc/syscall64-abi.rst 1535 1535 * 1536 1536 * For hypercalls, the register convention is as follows: 1537 1537 * r0 volatile
+1 -1
drivers/gpu/drm/drm_modes.c
··· 1686 1686 * 1687 1687 * Additionals options can be provided following the mode, using a comma to 1688 1688 * separate each option. Valid options can be found in 1689 - * Documentation/fb/modedb.txt. 1689 + * Documentation/fb/modedb.rst. 1690 1690 * 1691 1691 * The intermediate drm_cmdline_mode structure is required to store additional 1692 1692 * options from the command line modline like the force-enable/disable flag.
+1 -1
drivers/i2c/busses/i2c-nvidia-gpu.c
··· 364 364 /* 365 365 * We need gpu_i2c_suspend() even if it is stub, for runtime pm to work 366 366 * correctly. Without it, lspci shows runtime pm status as "D0" for the card. 367 - * Documentation/power/pci.txt also insists for driver to provide this. 367 + * Documentation/power/pci.rst also insists for driver to provide this. 368 368 */ 369 369 static __maybe_unused int gpu_i2c_suspend(struct device *dev) 370 370 {
+2 -2
drivers/scsi/hpsa.c
··· 7798 7798 hpsa_disable_interrupt_mode(h); /* pci_init 2 */ 7799 7799 /* 7800 7800 * call pci_disable_device before pci_release_regions per 7801 - * Documentation/PCI/pci.rst 7801 + * Documentation/driver-api/pci/pci.rst 7802 7802 */ 7803 7803 pci_disable_device(h->pdev); /* pci_init 1 */ 7804 7804 pci_release_regions(h->pdev); /* pci_init 2 */ ··· 7881 7881 clean1: 7882 7882 /* 7883 7883 * call pci_disable_device before pci_release_regions per 7884 - * Documentation/PCI/pci.rst 7884 + * Documentation/driver-api/pci/pci.rst 7885 7885 */ 7886 7886 pci_disable_device(h->pdev); 7887 7887 pci_release_regions(h->pdev);
+1 -1
drivers/soc/fsl/qe/qe.c
··· 419 419 /* 420 420 * Upload a microcode to the I-RAM at a specific address. 421 421 * 422 - * See Documentation/powerpc/qe_firmware.txt for information on QE microcode 422 + * See Documentation/powerpc/qe_firmware.rst for information on QE microcode 423 423 * uploading. 424 424 * 425 425 * Currently, only version 1 is supported, so the 'version' field must be
+1 -1
drivers/tty/hvc/hvcs.c
··· 47 47 * using the 2.6 Linux kernel kref construct. 48 48 * 49 49 * For direction on installation and usage of this driver please reference 50 - * Documentation/powerpc/hvcs.txt. 50 + * Documentation/powerpc/hvcs.rst. 51 51 */ 52 52 53 53 #include <linux/device.h>
+1 -1
include/soc/fsl/qe/qe.h
··· 259 259 260 260 /* Structure that defines QE firmware binary files. 261 261 * 262 - * See Documentation/powerpc/qe_firmware.txt for a description of these 262 + * See Documentation/powerpc/qe_firmware.rst for a description of these 263 263 * fields. 264 264 */ 265 265 struct qe_firmware {
+97 -21
scripts/sphinx-pre-install
··· 83 83 foreach my $prog (sort keys %missing) { 84 84 my $is_optional = $missing{$prog}; 85 85 86 + # At least on some LTS distros like CentOS 7, texlive doesn't 87 + # provide all packages we need. When such distros are 88 + # detected, we have to disable PDF output. 89 + # 90 + # So, we need to ignore the packages that distros would 91 + # need for LaTeX to work 92 + if ($is_optional == 2 && !$pdf) { 93 + $optional--; 94 + next; 95 + } 96 + 86 97 if ($is_optional) { 87 98 print "Warning: better to also install \"$prog\".\n"; 88 99 } else { ··· 344 333 345 334 if ($pdf) { 346 335 check_missing_file("/usr/share/fonts/truetype/dejavu/DejaVuSans.ttf", 347 - "fonts-dejavu", 1); 336 + "fonts-dejavu", 2); 337 + 338 + check_missing_file("/usr/share/fonts/noto-cjk/NotoSansCJK-Regular.ttc", 339 + "fonts-noto-cjk", 2); 348 340 } 349 341 350 - check_program("dvipng", 1) if ($pdf); 342 + check_program("dvipng", 2) if ($pdf); 351 343 check_missing(\%map); 352 344 353 345 return if (!$need && !$optional); ··· 377 363 my @fedora_tex_pkgs = ( 378 364 "texlive-collection-fontsrecommended", 379 365 "texlive-collection-latex", 366 + "texlive-xecjk", 380 367 "dejavu-sans-fonts", 381 368 "dejavu-serif-fonts", 382 369 "dejavu-sans-mono-fonts", ··· 386 371 # 387 372 # Checks valid for RHEL/CentOS version 7.x. 388 373 # 389 - if (! $system_release =~ /Fedora/) { 374 + my $old = 0; 375 + my $rel; 376 + $rel = $1 if ($system_release =~ /release\s+(\d+)/); 377 + 378 + if (!($system_release =~ /Fedora/)) { 390 379 $map{"virtualenv"} = "python-virtualenv"; 380 + 381 + if ($rel && $rel < 8) { 382 + $old = 1; 383 + $pdf = 0; 384 + 385 + printf("Note: texlive packages on RHEL/CENTOS <= 7 are incomplete. Can't support PDF output\n"); 386 + printf("If you want to build PDF, please read:\n"); 387 + printf("\thttps://www.systutorials.com/241660/how-to-install-tex-live-on-centos-7-linux/\n"); 388 + } 389 + } else { 390 + if ($rel && $rel < 26) { 391 + $old = 1; 392 + } 393 + } 394 + if (!$rel) { 395 + printf("Couldn't identify release number\n"); 396 + $old = 1; 397 + $pdf = 0; 391 398 } 392 399 393 - my $release; 400 + if ($pdf) { 401 + check_missing_file("/usr/share/fonts/google-noto-cjk/NotoSansCJK-Regular.ttc", 402 + "google-noto-sans-cjk-ttc-fonts", 2); 403 + } 394 404 395 - $release = $1 if ($system_release =~ /Fedora\s+release\s+(\d+)/); 396 - 397 - check_rpm_missing(\@fedora26_opt_pkgs, 1) if ($pdf && $release >= 26); 398 - check_rpm_missing(\@fedora_tex_pkgs, 1) if ($pdf); 399 - check_missing_tex(1) if ($pdf); 405 + check_rpm_missing(\@fedora26_opt_pkgs, 2) if ($pdf && !$old); 406 + check_rpm_missing(\@fedora_tex_pkgs, 2) if ($pdf); 407 + check_missing_tex(2) if ($pdf); 400 408 check_missing(\%map); 401 409 402 410 return if (!$need && !$optional); 403 411 404 - if ($release >= 18) { 412 + if (!$old) { 405 413 # dnf, for Fedora 18+ 406 414 printf("You should run:\n\n\tsudo dnf install -y $install\n"); 407 415 } else { ··· 463 425 "texlive-zapfding", 464 426 ); 465 427 466 - check_rpm_missing(\@suse_tex_pkgs, 1) if ($pdf); 467 - check_missing_tex(1) if ($pdf); 428 + $map{"latexmk"} = "texlive-latexmk-bin"; 429 + 430 + # FIXME: add support for installing CJK fonts 431 + # 432 + # I tried hard, but was unable to find a way to install 433 + # "Noto Sans CJK SC" on openSUSE 434 + 435 + check_rpm_missing(\@suse_tex_pkgs, 2) if ($pdf); 436 + check_missing_tex(2) if ($pdf); 468 437 check_missing(\%map); 469 438 470 439 return if (!$need && !$optional); ··· 495 450 "texlive-fontsextra", 496 451 ); 497 452 498 - check_rpm_missing(\@tex_pkgs, 1) if ($pdf); 453 + $map{"latexmk"} = "texlive-collection-basic"; 454 + 455 + if ($pdf) { 456 + check_missing_file("/usr/share/fonts/google-noto-cjk/NotoSansCJK-Regular.ttc", 457 + "google-noto-sans-cjk-ttc-fonts", 2); 458 + } 459 + 460 + check_rpm_missing(\@tex_pkgs, 2) if ($pdf); 499 461 check_missing(\%map); 500 462 501 463 return if (!$need && !$optional); ··· 525 473 "texlive-latexextra", 526 474 "ttf-dejavu", 527 475 ); 528 - check_pacman_missing(\@archlinux_tex_pkgs, 1) if ($pdf); 476 + check_pacman_missing(\@archlinux_tex_pkgs, 2) if ($pdf); 477 + 478 + if ($pdf) { 479 + check_missing_file("/usr/share/fonts/noto-cjk/NotoSansCJK-Regular.ttc", 480 + "noto-fonts-cjk", 2); 481 + } 482 + 529 483 check_missing(\%map); 530 484 531 485 return if (!$need && !$optional); ··· 550 492 ); 551 493 552 494 check_missing_file("/usr/share/fonts/dejavu/DejaVuSans.ttf", 553 - "media-fonts/dejavu", 1) if ($pdf); 495 + "media-fonts/dejavu", 2) if ($pdf); 496 + 497 + if ($pdf) { 498 + check_missing_file("/usr/share/fonts/noto-cjk/NotoSansCJKsc-Regular.otf", 499 + "media-fonts/noto-cjk", 2); 500 + } 554 501 555 502 check_missing(\%map); 556 503 557 504 return if (!$need && !$optional); 558 505 559 506 printf("You should run:\n\n"); 560 - printf("\tsudo su -c 'echo \"media-gfx/imagemagick svg png\" > /etc/portage/package.use/imagemagick'\n"); 561 - printf("\tsudo su -c 'echo \"media-gfx/graphviz cairo pdf\" > /etc/portage/package.use/graphviz'\n"); 507 + 508 + my $imagemagick = "media-gfx/imagemagick svg png"; 509 + my $cairo = "media-gfx/graphviz cairo pdf"; 510 + my $portage_imagemagick = "/etc/portage/package.use/imagemagick"; 511 + my $portage_cairo = "/etc/portage/package.use/graphviz"; 512 + 513 + if (qx(cat $portage_imagemagick) ne "$imagemagick\n") { 514 + printf("\tsudo su -c 'echo \"$imagemagick\" > $portage_imagemagick'\n") 515 + } 516 + if (qx(cat $portage_cairo) ne "$cairo\n") { 517 + printf("\tsudo su -c 'echo \"$cairo\" > $portage_cairo'\n"); 518 + } 519 + 562 520 printf("\tsudo emerge --ask $install\n"); 563 521 564 522 } ··· 634 560 my %map = ( 635 561 "sphinx-build" => "sphinx" 636 562 ); 637 - check_missing_tex(1) if ($pdf); 563 + check_missing_tex(2) if ($pdf); 638 564 check_missing(\%map); 639 565 print "I don't know distro $system_release.\n"; 640 566 print "So, I can't provide you a hint with the install procedure.\n"; ··· 663 589 check_program("make", 0); 664 590 check_program("gcc", 0); 665 591 check_python_module("sphinx_rtd_theme", 1) if (!$virtualenv); 666 - check_program("xelatex", 1) if ($pdf); 667 592 check_program("dot", 1); 668 593 check_program("convert", 1); 669 - check_program("rsvg-convert", 1) if ($pdf); 670 - check_program("latexmk", 1) if ($pdf); 594 + 595 + # Extra PDF files - should use 2 for is_optional 596 + check_program("xelatex", 2) if ($pdf); 597 + check_program("rsvg-convert", 2) if ($pdf); 598 + check_program("latexmk", 2) if ($pdf); 671 599 672 600 check_distros(); 673 601