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

Merge tag 'for-5.15/parisc' of git://git.kernel.org/pub/scm/linux/kernel/git/deller/parisc-linux

Pull parisc architecture updates from Helge Deller:

- Fix a kernel crash when a signal is delivered to bad userspace stack

- Fix fall-through warnings in math-emu code

- Increase size of gcc stack frame check

- Switch coding from 'pci_' to 'dma_' API

- Make struct parisc_driver::remove() return void

- Some parisc related Makefile changes

- Minor cleanups, e.g. change to octal permissions, fix macro
collisions, fix PMD_ORDER collision, replace spaces with tabs

* tag 'for-5.15/parisc' of git://git.kernel.org/pub/scm/linux/kernel/git/deller/parisc-linux:
parisc: math-emu: Fix fall-through warnings
parisc: fix crash with signals and alloca
parisc: Fix compile failure when building 64-bit kernel natively
parisc: ccio-dma.c: Added tab instead of spaces
parisc/parport_gsc: switch from 'pci_' to 'dma_' API
parisc: move core-y in arch/parisc/Makefile to arch/parisc/Kbuild
parisc: switch from 'pci_' to 'dma_' API
parisc: Make struct parisc_driver::remove() return void
parisc: remove unused arch/parisc/boot/install.sh and its phony target
parisc: Rename PMD_ORDER to PMD_TABLE_ORDER
parisc: math-emu: Avoid "fmt" macro collision
parisc: Increase size of gcc stack frame check
parisc: Replace symbolic permissions with octal permissions

+146 -170
+5
Makefile
··· 404 404 SRCARCH := sparc 405 405 endif 406 406 407 + # Additional ARCH settings for parisc 408 + ifeq ($(ARCH),parisc64) 409 + SRCARCH := parisc 410 + endif 411 + 407 412 export cross_compiling := 408 413 ifneq ($(SRCARCH),$(SUBARCH)) 409 414 cross_compiling := 1
+1
arch/parisc/Kbuild
··· 1 1 # SPDX-License-Identifier: GPL-2.0-only 2 + obj-y += mm/ kernel/ math-emu/
+3 -6
arch/parisc/Makefile
··· 25 25 ifdef CONFIG_64BIT 26 26 UTS_MACHINE := parisc64 27 27 CHECKFLAGS += -D__LP64__=1 28 - CC_ARCHES = hppa64 29 28 LD_BFD := elf64-hppa-linux 30 29 else # 32-bit 31 - CC_ARCHES = hppa hppa2.0 hppa1.1 32 30 LD_BFD := elf32-hppa-linux 33 31 endif 34 32 35 33 # select defconfig based on actual architecture 36 - ifeq ($(shell uname -m),parisc64) 34 + ifeq ($(ARCH),parisc64) 37 35 KBUILD_DEFCONFIG := generic-64bit_defconfig 36 + CC_ARCHES := hppa64 38 37 else 39 38 KBUILD_DEFCONFIG := generic-32bit_defconfig 39 + CC_ARCHES := hppa hppa2.0 hppa1.1 40 40 endif 41 41 42 42 export LD_BFD ··· 111 111 LIBGCC := $(shell $(CC) -print-libgcc-file-name) 112 112 export LIBGCC 113 113 114 - kernel-y := mm/ kernel/ math-emu/ 115 - 116 - core-y += $(addprefix arch/parisc/, $(kernel-y)) 117 114 libs-y += arch/parisc/lib/ $(LIBGCC) 118 115 119 116 boot := arch/parisc/boot
-4
arch/parisc/boot/Makefile
··· 15 15 16 16 $(obj)/compressed/vmlinux: FORCE 17 17 $(Q)$(MAKE) $(build)=$(obj)/compressed $@ 18 - 19 - install: $(CONFIGURE) $(obj)/bzImage 20 - sh -x $(srctree)/$(obj)/install.sh $(KERNELRELEASE) $(obj)/bzImage \ 21 - System.map "$(INSTALL_PATH)"
-65
arch/parisc/boot/install.sh
··· 1 - #!/bin/sh 2 - # 3 - # arch/parisc/install.sh, derived from arch/i386/boot/install.sh 4 - # 5 - # This file is subject to the terms and conditions of the GNU General Public 6 - # License. See the file "COPYING" in the main directory of this archive 7 - # for more details. 8 - # 9 - # Copyright (C) 1995 by Linus Torvalds 10 - # 11 - # Adapted from code in arch/i386/boot/Makefile by H. Peter Anvin 12 - # 13 - # "make install" script for i386 architecture 14 - # 15 - # Arguments: 16 - # $1 - kernel version 17 - # $2 - kernel image file 18 - # $3 - kernel map file 19 - # $4 - default install path (blank if root directory) 20 - # 21 - 22 - verify () { 23 - if [ ! -f "$1" ]; then 24 - echo "" 1>&2 25 - echo " *** Missing file: $1" 1>&2 26 - echo ' *** You need to run "make" before "make install".' 1>&2 27 - echo "" 1>&2 28 - exit 1 29 - fi 30 - } 31 - 32 - # Make sure the files actually exist 33 - 34 - verify "$2" 35 - verify "$3" 36 - 37 - # User may have a custom install script 38 - 39 - if [ -n "${INSTALLKERNEL}" ]; then 40 - if [ -x ~/bin/${INSTALLKERNEL} ]; then exec ~/bin/${INSTALLKERNEL} "$@"; fi 41 - if [ -x /sbin/${INSTALLKERNEL} ]; then exec /sbin/${INSTALLKERNEL} "$@"; fi 42 - fi 43 - 44 - # Default install 45 - 46 - if [ "$(basename $2)" = "zImage" ]; then 47 - # Compressed install 48 - echo "Installing compressed kernel" 49 - base=vmlinuz 50 - else 51 - # Normal install 52 - echo "Installing normal kernel" 53 - base=vmlinux 54 - fi 55 - 56 - if [ -f $4/$base-$1 ]; then 57 - mv $4/$base-$1 $4/$base-$1.old 58 - fi 59 - cat $2 > $4/$base-$1 60 - 61 - # Install system map file 62 - if [ -f $4/System.map-$1 ]; then 63 - mv $4/System.map-$1 $4/System.map-$1.old 64 - fi 65 - cp $3 $4/System.map-$1
+2 -2
arch/parisc/include/asm/parisc-device.h
··· 34 34 struct parisc_driver *next; 35 35 char *name; 36 36 const struct parisc_device_id *id_table; 37 - int (*probe) (struct parisc_device *dev); /* New device discovered */ 38 - int (*remove) (struct parisc_device *dev); 37 + int (*probe)(struct parisc_device *dev); /* New device discovered */ 38 + void (*remove)(struct parisc_device *dev); 39 39 struct device_driver drv; 40 40 }; 41 41
+3 -3
arch/parisc/include/asm/pgalloc.h
··· 48 48 { 49 49 pmd_t *pmd; 50 50 51 - pmd = (pmd_t *)__get_free_pages(GFP_PGTABLE_KERNEL, PMD_ORDER); 51 + pmd = (pmd_t *)__get_free_pages(GFP_PGTABLE_KERNEL, PMD_TABLE_ORDER); 52 52 if (likely(pmd)) 53 - memset ((void *)pmd, 0, PAGE_SIZE << PMD_ORDER); 53 + memset ((void *)pmd, 0, PAGE_SIZE << PMD_TABLE_ORDER); 54 54 return pmd; 55 55 } 56 56 57 57 static inline void pmd_free(struct mm_struct *mm, pmd_t *pmd) 58 58 { 59 - free_pages((unsigned long)pmd, PMD_ORDER); 59 + free_pages((unsigned long)pmd, PMD_TABLE_ORDER); 60 60 } 61 61 #endif 62 62
+2 -2
arch/parisc/include/asm/pgtable.h
··· 112 112 #define KERNEL_INITIAL_SIZE (1 << KERNEL_INITIAL_ORDER) 113 113 114 114 #if CONFIG_PGTABLE_LEVELS == 3 115 - #define PMD_ORDER 1 115 + #define PMD_TABLE_ORDER 1 116 116 #define PGD_ORDER 0 117 117 #else 118 118 #define PGD_ORDER 1 ··· 131 131 #define PMD_SHIFT (PLD_SHIFT + BITS_PER_PTE) 132 132 #define PMD_SIZE (1UL << PMD_SHIFT) 133 133 #define PMD_MASK (~(PMD_SIZE-1)) 134 - #define BITS_PER_PMD (PAGE_SHIFT + PMD_ORDER - BITS_PER_PMD_ENTRY) 134 + #define BITS_PER_PMD (PAGE_SHIFT + PMD_TABLE_ORDER - BITS_PER_PMD_ENTRY) 135 135 #define PTRS_PER_PMD (1UL << BITS_PER_PMD) 136 136 #else 137 137 #define BITS_PER_PMD 0
+6
arch/parisc/kernel/signal.c
··· 237 237 #endif 238 238 239 239 usp = (regs->gr[30] & ~(0x01UL)); 240 + #ifdef CONFIG_64BIT 241 + if (is_compat_task()) { 242 + /* The gcc alloca implementation leaves garbage in the upper 32 bits of sp */ 243 + usp = (compat_uint_t)usp; 244 + } 245 + #endif 240 246 /*FIXME: frame_size parameter is unused, remove it. */ 241 247 frame = get_sigframe(&ksig->ka, usp, sizeof(*frame)); 242 248
+2 -2
arch/parisc/math-emu/decode_exc.c
··· 46 46 #define SIGNALCODE(signal, code) ((signal) << 24 | (code)) 47 47 #define copropbit 1<<31-2 /* bit position 2 */ 48 48 #define opclass 9 /* bits 21 & 22 */ 49 - #define fmt 11 /* bits 19 & 20 */ 49 + #define fmtbits 11 /* bits 19 & 20 */ 50 50 #define df 13 /* bits 17 & 18 */ 51 51 #define twobits 3 /* mask low-order 2 bits */ 52 52 #define fivebits 31 /* mask low-order 5 bits */ ··· 57 57 #define Excp_instr(index) Instructionfield(Fpu_register[index]) 58 58 #define Clear_excp_register(index) Allexception(Fpu_register[index]) = 0 59 59 #define Excp_format() \ 60 - (current_ir >> ((current_ir>>opclass & twobits)==1 ? df : fmt) & twobits) 60 + (current_ir >> ((current_ir>>opclass & twobits) == 1 ? df : fmtbits) & twobits) 61 61 62 62 /* Miscellaneous definitions */ 63 63 #define Fpu_sgl(index) Fpu_register[index*2]
+53 -3
arch/parisc/math-emu/fpudispatch.c
··· 310 310 r1 &= ~3; 311 311 fpregs[t+3] = fpregs[r1+3]; 312 312 fpregs[t+2] = fpregs[r1+2]; 313 + fallthrough; 313 314 case 1: /* double */ 314 315 fpregs[t+1] = fpregs[r1+1]; 316 + fallthrough; 315 317 case 0: /* single */ 316 318 fpregs[t] = fpregs[r1]; 317 319 return(NOEXCEPTION); 318 320 } 321 + BUG(); 319 322 case 3: /* FABS */ 320 323 switch (fmt) { 321 324 case 2: /* illegal */ ··· 328 325 r1 &= ~3; 329 326 fpregs[t+3] = fpregs[r1+3]; 330 327 fpregs[t+2] = fpregs[r1+2]; 328 + fallthrough; 331 329 case 1: /* double */ 332 330 fpregs[t+1] = fpregs[r1+1]; 331 + fallthrough; 333 332 case 0: /* single */ 334 333 /* copy and clear sign bit */ 335 334 fpregs[t] = fpregs[r1] & 0x7fffffff; 336 335 return(NOEXCEPTION); 337 336 } 337 + BUG(); 338 338 case 6: /* FNEG */ 339 339 switch (fmt) { 340 340 case 2: /* illegal */ ··· 347 341 r1 &= ~3; 348 342 fpregs[t+3] = fpregs[r1+3]; 349 343 fpregs[t+2] = fpregs[r1+2]; 344 + fallthrough; 350 345 case 1: /* double */ 351 346 fpregs[t+1] = fpregs[r1+1]; 347 + fallthrough; 352 348 case 0: /* single */ 353 349 /* copy and invert sign bit */ 354 350 fpregs[t] = fpregs[r1] ^ 0x80000000; 355 351 return(NOEXCEPTION); 356 352 } 353 + BUG(); 357 354 case 7: /* FNEGABS */ 358 355 switch (fmt) { 359 356 case 2: /* illegal */ ··· 366 357 r1 &= ~3; 367 358 fpregs[t+3] = fpregs[r1+3]; 368 359 fpregs[t+2] = fpregs[r1+2]; 360 + fallthrough; 369 361 case 1: /* double */ 370 362 fpregs[t+1] = fpregs[r1+1]; 363 + fallthrough; 371 364 case 0: /* single */ 372 365 /* copy and set sign bit */ 373 366 fpregs[t] = fpregs[r1] | 0x80000000; 374 367 return(NOEXCEPTION); 375 368 } 369 + BUG(); 376 370 case 4: /* FSQRT */ 377 371 switch (fmt) { 378 372 case 0: ··· 388 376 case 3: /* quad not implemented */ 389 377 return(MAJOR_0C_EXCP); 390 378 } 379 + BUG(); 391 380 case 5: /* FRND */ 392 381 switch (fmt) { 393 382 case 0: ··· 402 389 return(MAJOR_0C_EXCP); 403 390 } 404 391 } /* end of switch (subop) */ 405 - 392 + BUG(); 406 393 case 1: /* class 1 */ 407 394 df = extru(ir,fpdfpos,2); /* get dest format */ 408 395 if ((df & 2) || (fmt & 2)) { ··· 432 419 case 3: /* dbl/dbl */ 433 420 return(MAJOR_0C_EXCP); 434 421 } 422 + BUG(); 435 423 case 1: /* FCNVXF */ 436 424 switch(fmt) { 437 425 case 0: /* sgl/sgl */ ··· 448 434 return(dbl_to_dbl_fcnvxf(&fpregs[r1],0, 449 435 &fpregs[t],status)); 450 436 } 437 + BUG(); 451 438 case 2: /* FCNVFX */ 452 439 switch(fmt) { 453 440 case 0: /* sgl/sgl */ ··· 464 449 return(dbl_to_dbl_fcnvfx(&fpregs[r1],0, 465 450 &fpregs[t],status)); 466 451 } 452 + BUG(); 467 453 case 3: /* FCNVFXT */ 468 454 switch(fmt) { 469 455 case 0: /* sgl/sgl */ ··· 480 464 return(dbl_to_dbl_fcnvfxt(&fpregs[r1],0, 481 465 &fpregs[t],status)); 482 466 } 467 + BUG(); 483 468 case 5: /* FCNVUF (PA2.0 only) */ 484 469 switch(fmt) { 485 470 case 0: /* sgl/sgl */ ··· 496 479 return(dbl_to_dbl_fcnvuf(&fpregs[r1],0, 497 480 &fpregs[t],status)); 498 481 } 482 + BUG(); 499 483 case 6: /* FCNVFU (PA2.0 only) */ 500 484 switch(fmt) { 501 485 case 0: /* sgl/sgl */ ··· 512 494 return(dbl_to_dbl_fcnvfu(&fpregs[r1],0, 513 495 &fpregs[t],status)); 514 496 } 497 + BUG(); 515 498 case 7: /* FCNVFUT (PA2.0 only) */ 516 499 switch(fmt) { 517 500 case 0: /* sgl/sgl */ ··· 528 509 return(dbl_to_dbl_fcnvfut(&fpregs[r1],0, 529 510 &fpregs[t],status)); 530 511 } 512 + BUG(); 531 513 case 4: /* undefined */ 532 514 return(MAJOR_0C_EXCP); 533 515 } /* end of switch subop */ 534 - 516 + BUG(); 535 517 case 2: /* class 2 */ 536 518 fpu_type_flags=fpregs[FPU_TYPE_FLAG_POS]; 537 519 r2 = extru(ir, fpr2pos, 5) * sizeof(double)/sizeof(u_int); ··· 610 590 case 3: /* quad not implemented */ 611 591 return(MAJOR_0C_EXCP); 612 592 } 593 + BUG(); 613 594 case 1: /* FTEST */ 614 595 switch (fmt) { 615 596 case 0: ··· 630 609 case 3: 631 610 return(MAJOR_0C_EXCP); 632 611 } 612 + BUG(); 633 613 } /* end of switch subop */ 634 614 } /* end of else for PA1.0 & PA1.1 */ 615 + BUG(); 635 616 case 3: /* class 3 */ 636 617 r2 = extru(ir,fpr2pos,5) * sizeof(double)/sizeof(u_int); 637 618 if (r2 == 0) ··· 656 633 case 3: /* quad not implemented */ 657 634 return(MAJOR_0C_EXCP); 658 635 } 636 + BUG(); 659 637 case 1: /* FSUB */ 660 638 switch (fmt) { 661 639 case 0: ··· 669 645 case 3: /* quad not implemented */ 670 646 return(MAJOR_0C_EXCP); 671 647 } 648 + BUG(); 672 649 case 2: /* FMPY */ 673 650 switch (fmt) { 674 651 case 0: ··· 682 657 case 3: /* quad not implemented */ 683 658 return(MAJOR_0C_EXCP); 684 659 } 660 + BUG(); 685 661 case 3: /* FDIV */ 686 662 switch (fmt) { 687 663 case 0: ··· 695 669 case 3: /* quad not implemented */ 696 670 return(MAJOR_0C_EXCP); 697 671 } 672 + BUG(); 698 673 case 4: /* FREM */ 699 674 switch (fmt) { 700 675 case 0: ··· 708 681 case 3: /* quad not implemented */ 709 682 return(MAJOR_0C_EXCP); 710 683 } 684 + BUG(); 711 685 } /* end of class 3 switch */ 712 686 } /* end of switch(class) */ 713 687 ··· 764 736 return(MAJOR_0E_EXCP); 765 737 case 1: /* double */ 766 738 fpregs[t+1] = fpregs[r1+1]; 739 + fallthrough; 767 740 case 0: /* single */ 768 741 fpregs[t] = fpregs[r1]; 769 742 return(NOEXCEPTION); 770 743 } 744 + BUG(); 771 745 case 3: /* FABS */ 772 746 switch (fmt) { 773 747 case 2: ··· 777 747 return(MAJOR_0E_EXCP); 778 748 case 1: /* double */ 779 749 fpregs[t+1] = fpregs[r1+1]; 750 + fallthrough; 780 751 case 0: /* single */ 781 752 fpregs[t] = fpregs[r1] & 0x7fffffff; 782 753 return(NOEXCEPTION); 783 754 } 755 + BUG(); 784 756 case 6: /* FNEG */ 785 757 switch (fmt) { 786 758 case 2: ··· 790 758 return(MAJOR_0E_EXCP); 791 759 case 1: /* double */ 792 760 fpregs[t+1] = fpregs[r1+1]; 761 + fallthrough; 793 762 case 0: /* single */ 794 763 fpregs[t] = fpregs[r1] ^ 0x80000000; 795 764 return(NOEXCEPTION); 796 765 } 766 + BUG(); 797 767 case 7: /* FNEGABS */ 798 768 switch (fmt) { 799 769 case 2: ··· 803 769 return(MAJOR_0E_EXCP); 804 770 case 1: /* double */ 805 771 fpregs[t+1] = fpregs[r1+1]; 772 + fallthrough; 806 773 case 0: /* single */ 807 774 fpregs[t] = fpregs[r1] | 0x80000000; 808 775 return(NOEXCEPTION); 809 776 } 777 + BUG(); 810 778 case 4: /* FSQRT */ 811 779 switch (fmt) { 812 780 case 0: ··· 821 785 case 3: 822 786 return(MAJOR_0E_EXCP); 823 787 } 788 + BUG(); 824 789 case 5: /* FRMD */ 825 790 switch (fmt) { 826 791 case 0: ··· 835 798 return(MAJOR_0E_EXCP); 836 799 } 837 800 } /* end of switch (subop */ 838 - 801 + BUG(); 839 802 case 1: /* class 1 */ 840 803 df = extru(ir,fpdfpos,2); /* get dest format */ 841 804 /* ··· 863 826 case 3: /* dbl/dbl */ 864 827 return(MAJOR_0E_EXCP); 865 828 } 829 + BUG(); 866 830 case 1: /* FCNVXF */ 867 831 switch(fmt) { 868 832 case 0: /* sgl/sgl */ ··· 879 841 return(dbl_to_dbl_fcnvxf(&fpregs[r1],0, 880 842 &fpregs[t],status)); 881 843 } 844 + BUG(); 882 845 case 2: /* FCNVFX */ 883 846 switch(fmt) { 884 847 case 0: /* sgl/sgl */ ··· 895 856 return(dbl_to_dbl_fcnvfx(&fpregs[r1],0, 896 857 &fpregs[t],status)); 897 858 } 859 + BUG(); 898 860 case 3: /* FCNVFXT */ 899 861 switch(fmt) { 900 862 case 0: /* sgl/sgl */ ··· 911 871 return(dbl_to_dbl_fcnvfxt(&fpregs[r1],0, 912 872 &fpregs[t],status)); 913 873 } 874 + BUG(); 914 875 case 5: /* FCNVUF (PA2.0 only) */ 915 876 switch(fmt) { 916 877 case 0: /* sgl/sgl */ ··· 927 886 return(dbl_to_dbl_fcnvuf(&fpregs[r1],0, 928 887 &fpregs[t],status)); 929 888 } 889 + BUG(); 930 890 case 6: /* FCNVFU (PA2.0 only) */ 931 891 switch(fmt) { 932 892 case 0: /* sgl/sgl */ ··· 943 901 return(dbl_to_dbl_fcnvfu(&fpregs[r1],0, 944 902 &fpregs[t],status)); 945 903 } 904 + BUG(); 946 905 case 7: /* FCNVFUT (PA2.0 only) */ 947 906 switch(fmt) { 948 907 case 0: /* sgl/sgl */ ··· 959 916 return(dbl_to_dbl_fcnvfut(&fpregs[r1],0, 960 917 &fpregs[t],status)); 961 918 } 919 + BUG(); 962 920 case 4: /* undefined */ 963 921 return(MAJOR_0C_EXCP); 964 922 } /* end of switch subop */ 923 + BUG(); 965 924 case 2: /* class 2 */ 966 925 /* 967 926 * Be careful out there. ··· 1039 994 } 1040 995 } /* end of switch subop */ 1041 996 } /* end of else for PA1.0 & PA1.1 */ 997 + BUG(); 1042 998 case 3: /* class 3 */ 1043 999 /* 1044 1000 * Be careful out there. ··· 1072 1026 return(dbl_fadd(&fpregs[r1],&fpregs[r2], 1073 1027 &fpregs[t],status)); 1074 1028 } 1029 + BUG(); 1075 1030 case 1: /* FSUB */ 1076 1031 switch (fmt) { 1077 1032 case 0: ··· 1082 1035 return(dbl_fsub(&fpregs[r1],&fpregs[r2], 1083 1036 &fpregs[t],status)); 1084 1037 } 1038 + BUG(); 1085 1039 case 2: /* FMPY or XMPYU */ 1086 1040 /* 1087 1041 * check for integer multiply (x bit set) ··· 1119 1071 &fpregs[r2],&fpregs[t],status)); 1120 1072 } 1121 1073 } 1074 + BUG(); 1122 1075 case 3: /* FDIV */ 1123 1076 switch (fmt) { 1124 1077 case 0: ··· 1129 1080 return(dbl_fdiv(&fpregs[r1],&fpregs[r2], 1130 1081 &fpregs[t],status)); 1131 1082 } 1083 + BUG(); 1132 1084 case 4: /* FREM */ 1133 1085 switch (fmt) { 1134 1086 case 0:
+2 -2
arch/parisc/mm/init.c
··· 378 378 379 379 #if CONFIG_PGTABLE_LEVELS == 3 380 380 if (pud_none(*pud)) { 381 - pmd = memblock_alloc(PAGE_SIZE << PMD_ORDER, 382 - PAGE_SIZE << PMD_ORDER); 381 + pmd = memblock_alloc(PAGE_SIZE << PMD_TABLE_ORDER, 382 + PAGE_SIZE << PMD_TABLE_ORDER); 383 383 if (!pmd) 384 384 panic("pmd allocation failed.\n"); 385 385 pud_populate(NULL, pud, pmd);
+1 -1
drivers/char/ipmi/ipmi_si.h
··· 73 73 void ipmi_irq_start_cleanup(struct si_sm_io *io); 74 74 int ipmi_std_irq_setup(struct si_sm_io *io); 75 75 void ipmi_irq_finish_setup(struct si_sm_io *io); 76 - int ipmi_si_remove_by_dev(struct device *dev); 76 + void ipmi_si_remove_by_dev(struct device *dev); 77 77 struct device *ipmi_si_remove_by_data(int addr_space, enum si_type si_type, 78 78 unsigned long addr); 79 79 void ipmi_hardcode_init(void);
+1 -5
drivers/char/ipmi/ipmi_si_intf.c
··· 2228 2228 kfree(smi_info); 2229 2229 } 2230 2230 2231 - int ipmi_si_remove_by_dev(struct device *dev) 2231 + void ipmi_si_remove_by_dev(struct device *dev) 2232 2232 { 2233 2233 struct smi_info *e; 2234 - int rv = -ENOENT; 2235 2234 2236 2235 mutex_lock(&smi_infos_lock); 2237 2236 list_for_each_entry(e, &smi_infos, link) { 2238 2237 if (e->io.dev == dev) { 2239 2238 cleanup_one_si(e); 2240 - rv = 0; 2241 2239 break; 2242 2240 } 2243 2241 } 2244 2242 mutex_unlock(&smi_infos_lock); 2245 - 2246 - return rv; 2247 2243 } 2248 2244 2249 2245 struct device *ipmi_si_remove_by_data(int addr_space, enum si_type si_type,
+2 -2
drivers/char/ipmi/ipmi_si_parisc.c
··· 29 29 return ipmi_si_add_smi(&io); 30 30 } 31 31 32 - static int __exit ipmi_parisc_remove(struct parisc_device *dev) 32 + static void __exit ipmi_parisc_remove(struct parisc_device *dev) 33 33 { 34 - return ipmi_si_remove_by_dev(&dev->dev); 34 + ipmi_si_remove_by_dev(&dev->dev); 35 35 } 36 36 37 37 static const struct parisc_device_id ipmi_parisc_tbl[] __initconst = {
+3 -1
drivers/char/ipmi/ipmi_si_platform.c
··· 411 411 412 412 static int ipmi_remove(struct platform_device *pdev) 413 413 { 414 - return ipmi_si_remove_by_dev(&pdev->dev); 414 + ipmi_si_remove_by_dev(&pdev->dev); 415 + 416 + return 0; 415 417 } 416 418 417 419 static int pdev_match_name(struct device *dev, const void *data)
+1 -3
drivers/input/keyboard/hilkbd.c
··· 316 316 return hil_keyb_init(); 317 317 } 318 318 319 - static int __exit hil_remove_chip(struct parisc_device *dev) 319 + static void __exit hil_remove_chip(struct parisc_device *dev) 320 320 { 321 321 hil_keyb_exit(); 322 - 323 - return 0; 324 322 } 325 323 326 324 static const struct parisc_device_id hil_tbl[] __initconst = {
+1 -2
drivers/input/serio/gscps2.c
··· 411 411 * @return: success/error report 412 412 */ 413 413 414 - static int __exit gscps2_remove(struct parisc_device *dev) 414 + static void __exit gscps2_remove(struct parisc_device *dev) 415 415 { 416 416 struct gscps2port *ps2port = dev_get_drvdata(&dev->dev); 417 417 ··· 425 425 #endif 426 426 dev_set_drvdata(&dev->dev, NULL); 427 427 kfree(ps2port); 428 - return 0; 429 428 } 430 429 431 430
+1 -2
drivers/net/ethernet/i825xx/lasi_82596.c
··· 196 196 return retval; 197 197 } 198 198 199 - static int __exit lan_remove_chip(struct parisc_device *pdev) 199 + static void __exit lan_remove_chip(struct parisc_device *pdev) 200 200 { 201 201 struct net_device *dev = parisc_get_drvdata(pdev); 202 202 struct i596_private *lp = netdev_priv(dev); ··· 205 205 dma_free_noncoherent(&pdev->dev, sizeof(struct i596_private), lp->dma, 206 206 lp->dma_addr, DMA_BIDIRECTIONAL); 207 207 free_netdev (dev); 208 - return 0; 209 208 } 210 209 211 210 static const struct parisc_device_id lan_tbl[] __initconst = {
+46 -46
drivers/parisc/ccio-dma.c
··· 111 111 #define CMD_TLB_PURGE 33 /* IO_COMMAND to Purge I/O TLB entry */ 112 112 113 113 struct ioa_registers { 114 - /* Runway Supervisory Set */ 115 - int32_t unused1[12]; 116 - uint32_t io_command; /* Offset 12 */ 117 - uint32_t io_status; /* Offset 13 */ 118 - uint32_t io_control; /* Offset 14 */ 119 - int32_t unused2[1]; 114 + /* Runway Supervisory Set */ 115 + int32_t unused1[12]; 116 + uint32_t io_command; /* Offset 12 */ 117 + uint32_t io_status; /* Offset 13 */ 118 + uint32_t io_control; /* Offset 14 */ 119 + int32_t unused2[1]; 120 120 121 - /* Runway Auxiliary Register Set */ 122 - uint32_t io_err_resp; /* Offset 0 */ 123 - uint32_t io_err_info; /* Offset 1 */ 124 - uint32_t io_err_req; /* Offset 2 */ 125 - uint32_t io_err_resp_hi; /* Offset 3 */ 126 - uint32_t io_tlb_entry_m; /* Offset 4 */ 127 - uint32_t io_tlb_entry_l; /* Offset 5 */ 128 - uint32_t unused3[1]; 129 - uint32_t io_pdir_base; /* Offset 7 */ 130 - uint32_t io_io_low_hv; /* Offset 8 */ 131 - uint32_t io_io_high_hv; /* Offset 9 */ 132 - uint32_t unused4[1]; 133 - uint32_t io_chain_id_mask; /* Offset 11 */ 134 - uint32_t unused5[2]; 135 - uint32_t io_io_low; /* Offset 14 */ 136 - uint32_t io_io_high; /* Offset 15 */ 121 + /* Runway Auxiliary Register Set */ 122 + uint32_t io_err_resp; /* Offset 0 */ 123 + uint32_t io_err_info; /* Offset 1 */ 124 + uint32_t io_err_req; /* Offset 2 */ 125 + uint32_t io_err_resp_hi; /* Offset 3 */ 126 + uint32_t io_tlb_entry_m; /* Offset 4 */ 127 + uint32_t io_tlb_entry_l; /* Offset 5 */ 128 + uint32_t unused3[1]; 129 + uint32_t io_pdir_base; /* Offset 7 */ 130 + uint32_t io_io_low_hv; /* Offset 8 */ 131 + uint32_t io_io_high_hv; /* Offset 9 */ 132 + uint32_t unused4[1]; 133 + uint32_t io_chain_id_mask; /* Offset 11 */ 134 + uint32_t unused5[2]; 135 + uint32_t io_io_low; /* Offset 14 */ 136 + uint32_t io_io_high; /* Offset 15 */ 137 137 }; 138 138 139 139 /* ··· 198 198 ** In order for a Runway address to reside within GSC+ extended address space: 199 199 ** Runway Address [0:7] must identically compare to 8'b11111111 200 200 ** Runway Address [8:11] must be equal to IO_IO_LOW(_HV)[16:19] 201 - ** Runway Address [12:23] must be greater than or equal to 201 + ** Runway Address [12:23] must be greater than or equal to 202 202 ** IO_IO_LOW(_HV)[20:31] and less than IO_IO_HIGH(_HV)[20:31]. 203 203 ** Runway Address [24:39] is not used in the comparison. 204 204 ** ··· 226 226 struct ioa_registers __iomem *ioc_regs; /* I/O MMU base address */ 227 227 u8 *res_map; /* resource map, bit == pdir entry */ 228 228 u64 *pdir_base; /* physical base address */ 229 - u32 pdir_size; /* bytes, function of IOV Space size */ 230 - u32 res_hint; /* next available IOVP - 229 + u32 pdir_size; /* bytes, function of IOV Space size */ 230 + u32 res_hint; /* next available IOVP - 231 231 circular search */ 232 - u32 res_size; /* size of resource map in bytes */ 232 + u32 res_size; /* size of resource map in bytes */ 233 233 spinlock_t res_lock; 234 234 235 235 #ifdef CCIO_COLLECT_STATS ··· 249 249 unsigned short cujo20_bug; 250 250 251 251 /* STUFF We don't need in performance path */ 252 - u32 chainid_shift; /* specify bit location of chain_id */ 252 + u32 chainid_shift; /* specify bit location of chain_id */ 253 253 struct ioc *next; /* Linked list of discovered iocs */ 254 254 const char *name; /* device name from firmware */ 255 255 unsigned int hw_path; /* the hardware path this ioc is associatd with */ ··· 293 293 ** cause the kernel to panic anyhow. 294 294 */ 295 295 #define CCIO_SEARCH_LOOP(ioc, res_idx, mask, size) \ 296 - for(; res_ptr < res_end; ++res_ptr) { \ 296 + for (; res_ptr < res_end; ++res_ptr) { \ 297 297 int ret;\ 298 298 unsigned int idx;\ 299 299 idx = (unsigned int)((unsigned long)res_ptr - (unsigned long)ioc->res_map); \ ··· 309 309 #define CCIO_FIND_FREE_MAPPING(ioa, res_idx, mask, size) \ 310 310 u##size *res_ptr = (u##size *)&((ioc)->res_map[ioa->res_hint & ~((size >> 3) - 1)]); \ 311 311 u##size *res_end = (u##size *)&(ioc)->res_map[ioa->res_size]; \ 312 - CCIO_SEARCH_LOOP(ioc, res_idx, mask, size); \ 313 - res_ptr = (u##size *)&(ioc)->res_map[0]; \ 314 - CCIO_SEARCH_LOOP(ioa, res_idx, mask, size); 312 + CCIO_SEARCH_LOOP(ioc, res_idx, mask, size); \ 313 + res_ptr = (u##size *)&(ioc)->res_map[0]; \ 314 + CCIO_SEARCH_LOOP(ioa, res_idx, mask, size); 315 315 316 316 /* 317 317 ** Find available bit in this ioa's resource map. ··· 348 348 349 349 BUG_ON(pages_needed == 0); 350 350 BUG_ON((pages_needed * IOVP_SIZE) > DMA_CHUNK_SIZE); 351 - 352 - DBG_RES("%s() size: %d pages_needed %d\n", 353 - __func__, size, pages_needed); 351 + 352 + DBG_RES("%s() size: %d pages_needed %d\n", 353 + __func__, size, pages_needed); 354 354 355 355 /* 356 356 ** "seek and ye shall find"...praying never hurts either... ··· 416 416 #define CCIO_FREE_MAPPINGS(ioc, res_idx, mask, size) \ 417 417 u##size *res_ptr = (u##size *)&((ioc)->res_map[res_idx]); \ 418 418 BUG_ON((*res_ptr & mask) != mask); \ 419 - *res_ptr &= ~(mask); 419 + *res_ptr &= ~(mask); 420 420 421 421 /** 422 422 * ccio_free_range - Free pages from the ioc's resource map. ··· 518 518 ** when it passes in BIDIRECTIONAL flag. 519 519 */ 520 520 static u32 hint_lookup[] = { 521 - [PCI_DMA_BIDIRECTIONAL] = HINT_STOP_MOST | HINT_SAFE_DMA | IOPDIR_VALID, 522 - [PCI_DMA_TODEVICE] = HINT_STOP_MOST | HINT_PREFETCH | IOPDIR_VALID, 523 - [PCI_DMA_FROMDEVICE] = HINT_STOP_MOST | IOPDIR_VALID, 521 + [DMA_BIDIRECTIONAL] = HINT_STOP_MOST | HINT_SAFE_DMA | IOPDIR_VALID, 522 + [DMA_TO_DEVICE] = HINT_STOP_MOST | HINT_PREFETCH | IOPDIR_VALID, 523 + [DMA_FROM_DEVICE] = HINT_STOP_MOST | IOPDIR_VALID, 524 524 }; 525 525 526 526 /** ··· 845 845 ccio_alloc(struct device *dev, size_t size, dma_addr_t *dma_handle, gfp_t flag, 846 846 unsigned long attrs) 847 847 { 848 - void *ret; 848 + void *ret; 849 849 #if 0 850 850 /* GRANT Need to establish hierarchy for non-PCI devs as well 851 851 ** and then provide matching gsc_map_xxx() functions for them as well. ··· 856 856 return 0; 857 857 } 858 858 #endif 859 - ret = (void *) __get_free_pages(flag, get_order(size)); 859 + ret = (void *) __get_free_pages(flag, get_order(size)); 860 860 861 861 if (ret) { 862 862 memset(ret, 0, size); 863 - *dma_handle = ccio_map_single(dev, ret, size, PCI_DMA_BIDIRECTIONAL); 863 + *dma_handle = ccio_map_single(dev, ret, size, DMA_BIDIRECTIONAL); 864 864 } 865 865 866 866 return ret; ··· 1022 1022 .free = ccio_free, 1023 1023 .map_page = ccio_map_page, 1024 1024 .unmap_page = ccio_unmap_page, 1025 - .map_sg = ccio_map_sg, 1026 - .unmap_sg = ccio_unmap_sg, 1025 + .map_sg = ccio_map_sg, 1026 + .unmap_sg = ccio_unmap_sg, 1027 1027 .get_sgtable = dma_common_get_sgtable, 1028 1028 .alloc_pages = dma_common_alloc_pages, 1029 1029 .free_pages = dma_common_free_pages, ··· 1080 1080 max = ioc->usingle_pages - ioc->usg_pages; 1081 1081 seq_printf(m, "pci_unmap_single: %8ld calls %8ld pages (avg %d/1000)\n", 1082 1082 min, max, (int)((max * 1000)/min)); 1083 - 1083 + 1084 1084 seq_printf(m, "pci_map_sg() : %8ld calls %8ld pages (avg %d/1000)\n", 1085 1085 ioc->msg_calls, ioc->msg_pages, 1086 1086 (int)((ioc->msg_pages * 1000)/ioc->msg_calls)); ··· 1169 1169 idx = PDIR_INDEX(iovp) >> 3; 1170 1170 1171 1171 while (idx < ioc->res_size) { 1172 - res_ptr[idx] |= 0xff; 1172 + res_ptr[idx] |= 0xff; 1173 1173 idx += PDIR_INDEX(CUJO_20_STEP) >> 3; 1174 1174 } 1175 1175 } ··· 1297 1297 DBG_INIT(" base %p\n", ioc->pdir_base); 1298 1298 1299 1299 /* resource map size dictated by pdir_size */ 1300 - ioc->res_size = (ioc->pdir_size / sizeof(u64)) >> 3; 1300 + ioc->res_size = (ioc->pdir_size / sizeof(u64)) >> 3; 1301 1301 DBG_INIT("%s() res_size 0x%x\n", __func__, ioc->res_size); 1302 1302 1303 1303 ioc->res_map = (u8 *)__get_free_pages(GFP_KERNEL,
+2 -2
drivers/parisc/led.c
··· 250 250 251 251 if (!lcd_no_led_support) 252 252 { 253 - ent = proc_create_data("led", S_IRUGO|S_IWUSR, proc_pdc_root, 253 + ent = proc_create_data("led", 0644, proc_pdc_root, 254 254 &led_proc_ops, (void *)LED_NOLCD); /* LED */ 255 255 if (!ent) return -1; 256 256 } 257 257 258 258 if (led_type == LED_HASLCD) 259 259 { 260 - ent = proc_create_data("lcd", S_IRUGO|S_IWUSR, proc_pdc_root, 260 + ent = proc_create_data("lcd", 0644, proc_pdc_root, 261 261 &led_proc_ops, (void *)LED_HASLCD); /* LCD */ 262 262 if (!ent) return -1; 263 263 }
+3 -5
drivers/parport/parport_gsc.c
··· 378 378 return 0; 379 379 } 380 380 381 - static int __exit parport_remove_chip(struct parisc_device *dev) 381 + static void __exit parport_remove_chip(struct parisc_device *dev) 382 382 { 383 383 struct parport *p = dev_get_drvdata(&dev->dev); 384 384 if (p) { ··· 390 390 if (p->irq != PARPORT_IRQ_NONE) 391 391 free_irq(p->irq, p); 392 392 if (priv->dma_buf) 393 - pci_free_consistent(priv->dev, PAGE_SIZE, 394 - priv->dma_buf, 395 - priv->dma_handle); 393 + dma_free_coherent(&priv->dev->dev, PAGE_SIZE, 394 + priv->dma_buf, priv->dma_handle); 396 395 kfree (p->private_data); 397 396 parport_put_port(p); 398 397 kfree (ops); /* hope no-one cached it */ 399 398 } 400 - return 0; 401 399 } 402 400 403 401 static const struct parisc_device_id parport_tbl[] __initconst = {
+1 -3
drivers/scsi/lasi700.c
··· 134 134 return -ENODEV; 135 135 } 136 136 137 - static int __exit 137 + static void __exit 138 138 lasi700_driver_remove(struct parisc_device *dev) 139 139 { 140 140 struct Scsi_Host *host = dev_get_drvdata(&dev->dev); ··· 146 146 free_irq(host->irq, host); 147 147 iounmap(hostdata->base); 148 148 kfree(hostdata); 149 - 150 - return 0; 151 149 } 152 150 153 151 static struct parisc_driver lasi700_driver __refdata = {
+1 -3
drivers/scsi/zalon.c
··· 168 168 169 169 MODULE_DEVICE_TABLE(parisc, zalon_tbl); 170 170 171 - static int __exit zalon_remove(struct parisc_device *dev) 171 + static void __exit zalon_remove(struct parisc_device *dev) 172 172 { 173 173 struct Scsi_Host *host = dev_get_drvdata(&dev->dev); 174 174 175 175 scsi_remove_host(host); 176 176 ncr53c8xx_release(host); 177 177 free_irq(dev->irq, host); 178 - 179 - return 0; 180 178 } 181 179 182 180 static struct parisc_driver zalon_driver __refdata = {
+1 -2
drivers/tty/serial/mux.c
··· 496 496 return 0; 497 497 } 498 498 499 - static int __exit mux_remove(struct parisc_device *dev) 499 + static void __exit mux_remove(struct parisc_device *dev) 500 500 { 501 501 int i, j; 502 502 int port_count = (long)dev_get_drvdata(&dev->dev); ··· 518 518 } 519 519 520 520 release_mem_region(dev->hpa.start + MUX_OFFSET, port_count * MUX_LINE_OFFSET); 521 - return 0; 522 521 } 523 522 524 523 /* Hack. This idea was taken from the 8250_gsc.c on how to properly order
+1 -1
lib/Kconfig.debug
··· 346 346 int "Warn for stack frames larger than" 347 347 range 0 8192 348 348 default 2048 if GCC_PLUGIN_LATENT_ENTROPY 349 - default 1280 if (!64BIT && PARISC) 349 + default 1536 if (!64BIT && PARISC) 350 350 default 1024 if (!64BIT && !PARISC) 351 351 default 2048 if 64BIT 352 352 help
+1 -1
scripts/subarch.include
··· 7 7 SUBARCH := $(shell uname -m | sed -e s/i.86/x86/ -e s/x86_64/x86/ \ 8 8 -e s/sun4u/sparc64/ \ 9 9 -e s/arm.*/arm/ -e s/sa110/arm/ \ 10 - -e s/s390x/s390/ -e s/parisc64/parisc/ \ 10 + -e s/s390x/s390/ \ 11 11 -e s/ppc.*/powerpc/ -e s/mips.*/mips/ \ 12 12 -e s/sh[234].*/sh/ -e s/aarch64.*/arm64/ \ 13 13 -e s/riscv.*/riscv/)
+1 -2
sound/parisc/harmony.c
··· 954 954 return err; 955 955 } 956 956 957 - static int __exit 957 + static void __exit 958 958 snd_harmony_remove(struct parisc_device *padev) 959 959 { 960 960 snd_card_free(parisc_get_drvdata(padev)); 961 - return 0; 962 961 } 963 962 964 963 static struct parisc_driver snd_harmony_driver __refdata = {