···2121endif22222323LDFLAGS_vmlinux := -Ttext $(KERNELLOAD) -Bstatic2424-CPPFLAGS += -Iarch/$(ARCH)2424+CPPFLAGS += -Iarch/$(ARCH) -Iinclude32525AFLAGS += -Iarch/$(ARCH)2626CFLAGS += -Iarch/$(ARCH) -msoft-float -pipe \2727 -ffixed-r2 -mmultiple2828CPP = $(CC) -E $(CFLAGS)2929+# Temporary hack until we have migrated to asm-powerpc3030+LINUXINCLUDE += -Iinclude329313032CHECKFLAGS += -D__powerpc__3133···103101104102archclean:105103 $(Q)$(MAKE) $(clean)=arch/ppc/boot104104+ $(Q)rm -rf include3106105107106prepare: include/asm-$(ARCH)/offsets.h checkbin108107···112109113110include/asm-$(ARCH)/offsets.h: arch/$(ARCH)/kernel/asm-offsets.s114111 $(call filechk,gen-asm-offsets)112112+113113+# Temporary hack until we have migrated to asm-powerpc114114+include/asm: include3/asm115115+include3/asm:116116+ $(Q)if [ ! -d include3 ]; then mkdir -p include3; fi117117+ $(Q)ln -fsn $(srctree)/include/asm-powerpc include3/asm115118116119# Use the file '.tmp_gas_check' for binutils tests, as gas won't output117120# to stdout and these checks are run even on install targets.
+9
arch/ppc64/Makefile
···5555LDFLAGS_vmlinux := -Bstatic -e $(KERNELLOAD) -Ttext $(KERNELLOAD)5656CFLAGS += -msoft-float -pipe -mminimal-toc -mtraceback=none \5757 -mcall-aixdesc5858+# Temporary hack until we have migrated to asm-powerpc5959+CPPFLAGS += -Iinclude358605961GCC_VERSION := $(call cc-version)6062GCC_BROKEN_VEC := $(shell if [ $(GCC_VERSION) -lt 0400 ] ; then echo "y"; fi ;)···114112115113archclean:116114 $(Q)$(MAKE) $(clean)=$(boot)115115+ $(Q)rm -rf include3117116118117prepare: include/asm-ppc64/offsets.h119118···123120124121include/asm-ppc64/offsets.h: arch/ppc64/kernel/asm-offsets.s125122 $(call filechk,gen-asm-offsets)123123+124124+# Temporary hack until we have migrated to asm-powerpc125125+include/asm: include3/asm126126+include3/asm:127127+ $(Q)if [ ! -d include3 ]; then mkdir -p include3; fi;128128+ $(Q)ln -fsn $(srctree)/include/asm-powerpc include3/asm126129127130define archhelp128131 echo '* zImage - Compressed kernel image (arch/$(ARCH)/boot/zImage)'
+3-3
arch/ppc64/configs/g5_defconfig
···103103# CONFIG_PREEMPT_VOLUNTARY is not set104104# CONFIG_PREEMPT is not set105105# CONFIG_PREEMPT_BKL is not set106106-CONFIG_HZ_100=y107107-# CONFIG_HZ_250 is not set106106+# CONFIG_HZ_100 is not set107107+CONFIG_HZ_250=y108108# CONFIG_HZ_1000 is not set109109-CONFIG_HZ=100109109+CONFIG_HZ=250110110CONFIG_GENERIC_HARDIRQS=y111111CONFIG_SECCOMP=y112112CONFIG_ISA_DMA_API=y
+3-3
arch/ppc64/configs/iSeries_defconfig
···9494# CONFIG_PREEMPT_VOLUNTARY is not set9595# CONFIG_PREEMPT is not set9696# CONFIG_PREEMPT_BKL is not set9797-CONFIG_HZ_100=y9898-# CONFIG_HZ_250 is not set9797+# CONFIG_HZ_100 is not set9898+CONFIG_HZ_250=y9999# CONFIG_HZ_1000 is not set100100-CONFIG_HZ=100100100+CONFIG_HZ=250101101CONFIG_GENERIC_HARDIRQS=y102102CONFIG_LPARCFG=y103103CONFIG_SECCOMP=y
+3-3
arch/ppc64/configs/maple_defconfig
···103103# CONFIG_PREEMPT_VOLUNTARY is not set104104# CONFIG_PREEMPT is not set105105# CONFIG_PREEMPT_BKL is not set106106-CONFIG_HZ_100=y107107-# CONFIG_HZ_250 is not set106106+# CONFIG_HZ_100 is not set107107+CONFIG_HZ_250=y108108# CONFIG_HZ_1000 is not set109109-CONFIG_HZ=100109109+CONFIG_HZ=250110110CONFIG_GENERIC_HARDIRQS=y111111CONFIG_SECCOMP=y112112CONFIG_ISA_DMA_API=y
+3-3
arch/ppc64/configs/pSeries_defconfig
···112112# CONFIG_PREEMPT_VOLUNTARY is not set113113# CONFIG_PREEMPT is not set114114# CONFIG_PREEMPT_BKL is not set115115-CONFIG_HZ_100=y116116-# CONFIG_HZ_250 is not set115115+# CONFIG_HZ_100 is not set116116+CONFIG_HZ_250=y117117# CONFIG_HZ_1000 is not set118118-CONFIG_HZ=100118118+CONFIG_HZ=250119119CONFIG_EEH=y120120CONFIG_GENERIC_HARDIRQS=y121121CONFIG_PPC_RTAS=y
+3-3
arch/ppc64/defconfig
···114114# CONFIG_PREEMPT_VOLUNTARY is not set115115# CONFIG_PREEMPT is not set116116# CONFIG_PREEMPT_BKL is not set117117-CONFIG_HZ_100=y118118-# CONFIG_HZ_250 is not set117117+# CONFIG_HZ_100 is not set118118+CONFIG_HZ_250=y119119# CONFIG_HZ_1000 is not set120120-CONFIG_HZ=100120120+CONFIG_HZ=250121121CONFIG_EEH=y122122CONFIG_GENERIC_HARDIRQS=y123123CONFIG_PPC_RTAS=y
+15-1
arch/ppc64/kernel/head.S
···12691269 .= 0x700012701270 .globl fwnmi_data_area12711271fwnmi_data_area:12721272- .space PAGE_SIZE12721272+12731273+ /* iSeries does not use the FWNMI stuff, so it is safe to put12741274+ * this here, even if we later allow kernels that will boot on12751275+ * both pSeries and iSeries */12761276+#ifdef CONFIG_PPC_ISERIES12771277+ . = LPARMAP_PHYS12781278+#include "lparmap.s"12791279+/*12801280+ * This ".text" is here for old compilers that generate a trailing12811281+ * .note section when compiling .c files to .s12821282+ */12831283+ .text12841284+#endif /* CONFIG_PPC_ISERIES */12851285+12861286+ . = 0x80001273128712741288/*12751289 * On pSeries, secondary processors spin in the following code.
+16-5
arch/ppc64/kernel/iSeries_vio.c
···6868}69697070/**7171- * vio_register_device: - Register a new vio device.7171+ * vio_register_device_iseries: - Register a new iSeries vio device.7272 * @voidev: The device to register.7373 */7474static struct vio_dev *__init vio_register_device_iseries(char *type,···7676{7777 struct vio_dev *viodev;78787979- /* allocate a vio_dev for this node */7979+ /* allocate a vio_dev for this device */8080 viodev = kmalloc(sizeof(struct vio_dev), GFP_KERNEL);8181 if (!viodev)8282 return NULL;···84848585 snprintf(viodev->dev.bus_id, BUS_ID_SIZE, "%s%d", type, unit_num);86868787- return vio_register_device_common(viodev, viodev->dev.bus_id, type,8888- unit_num, &vio_iommu_table);8787+ viodev->name = viodev->dev.bus_id;8888+ viodev->type = type;8989+ viodev->unit_address = unit_num;9090+ viodev->iommu_table = &vio_iommu_table;9191+ if (vio_register_device(viodev) == NULL) {9292+ kfree(viodev);9393+ return NULL;9494+ }9595+ return viodev;8996}90979198void __init probe_bus_iseries(void)···131124 return strncmp(dev->type, id->type, strlen(id->type)) == 0;132125}133126127127+static struct vio_bus_ops vio_bus_ops_iseries = {128128+ .match = vio_match_device_iseries,129129+};130130+134131/**135132 * vio_bus_init_iseries: - Initialize the iSeries virtual IO bus136133 */···142131{143132 int err;144133145145- err = vio_bus_init(vio_match_device_iseries, NULL, NULL);134134+ err = vio_bus_init(&vio_bus_ops_iseries);146135 if (err == 0) {147136 iommu_vio_init();148137 vio_bus_device.iommu_table = &vio_iommu_table;
+1
arch/ppc64/kernel/lparcfg.c
···273273 if (!workbuffer) {274274 printk(KERN_ERR "%s %s kmalloc failure at line %d \n",275275 __FILE__, __FUNCTION__, __LINE__);276276+ kfree(local_buffer); 276277 return;277278 }278279#ifdef LPARCFG_DEBUG
···892892 if ( RELOC(of_platform) == PLATFORM_PSERIES_LPAR )893893 RELOC(alloc_top) = RELOC(rmo_top);894894 else895895- RELOC(alloc_top) = RELOC(rmo_top) = min(0x40000000ul, RELOC(ram_top));895895+ /* Some RS64 machines have buggy firmware where claims up at 1GB896896+ * fails. Cap at 768MB as a workaround. Still plenty of room.897897+ */898898+ RELOC(alloc_top) = RELOC(rmo_top) = min(0x30000000ul, RELOC(ram_top));896899897900 prom_printf("memory layout at init:\n");898901 prom_printf(" memory_limit : %x (16 MB aligned)\n", RELOC(prom_memory_limit));
+27-46
arch/ppc64/kernel/vio.c
···3232 .dev.bus = &vio_bus_type,3333};34343535-static int (*is_match)(const struct vio_device_id *id,3636- const struct vio_dev *dev);3737-static void (*unregister_device_callback)(struct vio_dev *dev);3838-static void (*release_device_callback)(struct device *dev);3535+static struct vio_bus_ops vio_bus_ops;39364040-/* convert from struct device to struct vio_dev and pass to driver.3737+/*3838+ * Convert from struct device to struct vio_dev and pass to driver.4139 * dev->driver has already been set by generic code because vio_bus_match4242- * succeeded. */4040+ * succeeded.4141+ */4342static int vio_bus_probe(struct device *dev)4443{4544 struct vio_dev *viodev = to_vio_dev(dev);···5051 return error;51525253 id = vio_match_device(viodrv->id_table, viodev);5353- if (id) {5454+ if (id)5455 error = viodrv->probe(viodev, id);5555- }56565757 return error;5858}···6264 struct vio_dev *viodev = to_vio_dev(dev);6365 struct vio_driver *viodrv = to_vio_driver(dev->driver);64666565- if (viodrv->remove) {6767+ if (viodrv->remove)6668 return viodrv->remove(viodev);6767- }68696970 /* driver can't remove */7071 return 1;···99102EXPORT_SYMBOL(vio_unregister_driver);100103101104/**102102- * vio_match_device: - Tell if a VIO device has a matching VIO device id structure.103103- * @ids: array of VIO device id structures to search in104104- * @dev: the VIO device structure to match against105105+ * vio_match_device: - Tell if a VIO device has a matching106106+ * VIO device id structure.107107+ * @ids: array of VIO device id structures to search in108108+ * @dev: the VIO device structure to match against105109 *106110 * Used by a driver to check whether a VIO device present in the107111 * system is in its list of supported devices. Returns the matching108112 * vio_device_id structure or NULL if there is no match.109113 */110110-static const struct vio_device_id * vio_match_device(const struct vio_device_id *ids,111111- const struct vio_dev *dev)114114+static const struct vio_device_id *vio_match_device(115115+ const struct vio_device_id *ids, const struct vio_dev *dev)112116{113113- while (ids->type) {114114- if (is_match(ids, dev))117117+ while (ids->type[0] != '\0') {118118+ if (vio_bus_ops.match(ids, dev))115119 return ids;116120 ids++;117121 }···122124/**123125 * vio_bus_init: - Initialize the virtual IO bus124126 */125125-int __init vio_bus_init(int (*match_func)(const struct vio_device_id *id,126126- const struct vio_dev *dev),127127- void (*unregister_dev)(struct vio_dev *),128128- void (*release_dev)(struct device *))127127+int __init vio_bus_init(struct vio_bus_ops *ops)129128{130129 int err;131130132132- is_match = match_func;133133- unregister_device_callback = unregister_dev;134134- release_device_callback = release_dev;131131+ vio_bus_ops = *ops;135132136133 err = bus_register(&vio_bus_type);137134 if (err) {···134141 return err;135142 }136143137137- /* the fake parent of all vio devices, just to give us144144+ /*145145+ * The fake parent of all vio devices, just to give us138146 * a nice directory139147 */140148 err = device_register(&vio_bus_device.dev);···151157/* vio_dev refcount hit 0 */152158static void __devinit vio_dev_release(struct device *dev)153159{154154- if (release_device_callback)155155- release_device_callback(dev);160160+ if (vio_bus_ops.release_device)161161+ vio_bus_ops.release_device(dev);156162 kfree(to_vio_dev(dev));157163}158164159159-static ssize_t viodev_show_name(struct device *dev, struct device_attribute *attr, char *buf)165165+static ssize_t viodev_show_name(struct device *dev,166166+ struct device_attribute *attr, char *buf)160167{161168 return sprintf(buf, "%s\n", to_vio_dev(dev)->name);162169}163170DEVICE_ATTR(name, S_IRUSR | S_IRGRP | S_IROTH, viodev_show_name, NULL);164171165165-struct vio_dev * __devinit vio_register_device_common(166166- struct vio_dev *viodev, char *name, char *type,167167- uint32_t unit_address, struct iommu_table *iommu_table)172172+struct vio_dev * __devinit vio_register_device(struct vio_dev *viodev)168173{169169- viodev->name = name;170170- viodev->type = type;171171- viodev->unit_address = unit_address;172172- viodev->iommu_table = iommu_table;173174 /* init generic 'struct device' fields: */174175 viodev->dev.parent = &vio_bus_device.dev;175176 viodev->dev.bus = &vio_bus_type;···183194184195void __devinit vio_unregister_device(struct vio_dev *viodev)185196{186186- if (unregister_device_callback)187187- unregister_device_callback(viodev);197197+ if (vio_bus_ops.unregister_device)198198+ vio_bus_ops.unregister_device(viodev);188199 device_remove_file(&viodev->dev, &dev_attr_name);189200 device_unregister(&viodev->dev);190201}···251262 const struct vio_dev *vio_dev = to_vio_dev(dev);252263 struct vio_driver *vio_drv = to_vio_driver(drv);253264 const struct vio_device_id *ids = vio_drv->id_table;254254- const struct vio_device_id *found_id;255265256256- if (!ids)257257- return 0;258258-259259- found_id = vio_match_device(ids, vio_dev);260260- if (found_id)261261- return 1;262262-263263- return 0;266266+ return (ids != NULL) && (vio_match_device(ids, vio_dev) != NULL);264267}265268266269struct bus_type vio_bus_type = {
+1-3
arch/ppc64/mm/hash_low.S
···129129 * code rather than call a C function...) 130130 */131131BEGIN_FTR_SECTION132132-BEGIN_FTR_SECTION133132 mr r4,r30134133 mr r5,r7135134 bl .hash_page_do_lazy_icache136136-END_FTR_SECTION_IFSET(CPU_FTR_NOEXECUTE)137137-END_FTR_SECTION_IFCLR(CPU_FTR_COHERENT_ICACHE)135135+END_FTR_SECTION(CPU_FTR_NOEXECUTE|CPU_FTR_COHERENT_ICACHE, CPU_FTR_NOEXECUTE)138136139137 /* At this point, r3 contains new PP bits, save them in140138 * place of "access" in the param area (sic)
+1
arch/ppc64/oprofile/common.c
···153153154154 case PV_970:155155 case PV_970FX:156156+ case PV_970MP:156157 model = &op_model_power4;157158 model->num_counters = 8;158159 ops->cpu_type = "ppc64/970";
···11-#ifndef _PPC64_ERRNO_H22-#define _PPC64_ERRNO_H33-44-/* 55- * This program is free software; you can redistribute it and/or66- * modify it under the terms of the GNU General Public License77- * as published by the Free Software Foundation; either version88- * 2 of the License, or (at your option) any later version.99- */1010-1111-#include <asm-generic/errno.h>1212-1313-#undef EDEADLOCK1414-#define EDEADLOCK 58 /* File locking deadlock error */1515-1616-#define _LAST_ERRNO 5161717-1818-#endif
···11-#ifndef _PPC64_IOCTL_H22-#define _PPC64_IOCTL_H33-44-55-/*66- * This was copied from the alpha as it's a bit cleaner there.77- * -- Cort88- *99- * This program is free software; you can redistribute it and/or1010- * modify it under the terms of the GNU General Public License1111- * as published by the Free Software Foundation; either version1212- * 2 of the License, or (at your option) any later version.1313- */1414-1515-#define _IOC_NRBITS 81616-#define _IOC_TYPEBITS 81717-#define _IOC_SIZEBITS 131818-#define _IOC_DIRBITS 31919-2020-#define _IOC_NRMASK ((1 << _IOC_NRBITS)-1)2121-#define _IOC_TYPEMASK ((1 << _IOC_TYPEBITS)-1)2222-#define _IOC_SIZEMASK ((1 << _IOC_SIZEBITS)-1)2323-#define _IOC_DIRMASK ((1 << _IOC_DIRBITS)-1)2424-2525-#define _IOC_NRSHIFT 02626-#define _IOC_TYPESHIFT (_IOC_NRSHIFT+_IOC_NRBITS)2727-#define _IOC_SIZESHIFT (_IOC_TYPESHIFT+_IOC_TYPEBITS)2828-#define _IOC_DIRSHIFT (_IOC_SIZESHIFT+_IOC_SIZEBITS)2929-3030-/*3131- * Direction bits _IOC_NONE could be 0, but OSF/1 gives it a bit.3232- * And this turns out useful to catch old ioctl numbers in header3333- * files for us.3434- */3535-#define _IOC_NONE 1U3636-#define _IOC_READ 2U3737-#define _IOC_WRITE 4U3838-3939-#define _IOC(dir,type,nr,size) \4040- (((dir) << _IOC_DIRSHIFT) | \4141- ((type) << _IOC_TYPESHIFT) | \4242- ((nr) << _IOC_NRSHIFT) | \4343- ((size) << _IOC_SIZESHIFT))4444-4545-/* provoke compile error for invalid uses of size argument */4646-extern unsigned int __invalid_size_argument_for_IOC;4747-#define _IOC_TYPECHECK(t) \4848- ((sizeof(t) == sizeof(t[1]) && \4949- sizeof(t) < (1 << _IOC_SIZEBITS)) ? \5050- sizeof(t) : __invalid_size_argument_for_IOC)5151-5252-/* used to create numbers */5353-#define _IO(type,nr) _IOC(_IOC_NONE,(type),(nr),0)5454-#define _IOR(type,nr,size) _IOC(_IOC_READ,(type),(nr),(_IOC_TYPECHECK(size)))5555-#define _IOW(type,nr,size) _IOC(_IOC_WRITE,(type),(nr),(_IOC_TYPECHECK(size)))5656-#define _IOWR(type,nr,size) _IOC(_IOC_READ|_IOC_WRITE,(type),(nr),(_IOC_TYPECHECK(size)))5757-#define _IOR_BAD(type,nr,size) _IOC(_IOC_READ,(type),(nr),sizeof(size))5858-#define _IOW_BAD(type,nr,size) _IOC(_IOC_WRITE,(type),(nr),sizeof(size))5959-#define _IOWR_BAD(type,nr,size) _IOC(_IOC_READ|_IOC_WRITE,(type),(nr),sizeof(size))6060-6161-/* used to decode them.. */6262-#define _IOC_DIR(nr) (((nr) >> _IOC_DIRSHIFT) & _IOC_DIRMASK)6363-#define _IOC_TYPE(nr) (((nr) >> _IOC_TYPESHIFT) & _IOC_TYPEMASK)6464-#define _IOC_NR(nr) (((nr) >> _IOC_NRSHIFT) & _IOC_NRMASK)6565-#define _IOC_SIZE(nr) (((nr) >> _IOC_SIZESHIFT) & _IOC_SIZEMASK)6666-6767-/* various drivers, such as the pcmcia stuff, need these... */6868-#define IOC_IN (_IOC_WRITE << _IOC_DIRSHIFT)6969-#define IOC_OUT (_IOC_READ << _IOC_DIRSHIFT)7070-#define IOC_INOUT ((_IOC_WRITE|_IOC_READ) << _IOC_DIRSHIFT)7171-#define IOCSIZE_MASK (_IOC_SIZEMASK << _IOC_SIZESHIFT)7272-#define IOCSIZE_SHIFT (_IOC_SIZESHIFT)7373-7474-#endif /* _PPC64_IOCTL_H */
-114
include/asm-ppc64/ioctls.h
···11-#ifndef _ASM_PPC64_IOCTLS_H22-#define _ASM_PPC64_IOCTLS_H33-44-/*55- * This program is free software; you can redistribute it and/or66- * modify it under the terms of the GNU General Public License77- * as published by the Free Software Foundation; either version88- * 2 of the License, or (at your option) any later version.99- */1010-1111-#include <asm/ioctl.h>1212-1313-#define FIOCLEX _IO('f', 1)1414-#define FIONCLEX _IO('f', 2)1515-#define FIOASYNC _IOW('f', 125, int)1616-#define FIONBIO _IOW('f', 126, int)1717-#define FIONREAD _IOR('f', 127, int)1818-#define TIOCINQ FIONREAD1919-#define FIOQSIZE _IOR('f', 128, loff_t)2020-2121-#define TIOCGETP _IOR('t', 8, struct sgttyb)2222-#define TIOCSETP _IOW('t', 9, struct sgttyb)2323-#define TIOCSETN _IOW('t', 10, struct sgttyb) /* TIOCSETP wo flush */2424-2525-#define TIOCSETC _IOW('t', 17, struct tchars)2626-#define TIOCGETC _IOR('t', 18, struct tchars)2727-#define TCGETS _IOR('t', 19, struct termios)2828-#define TCSETS _IOW('t', 20, struct termios)2929-#define TCSETSW _IOW('t', 21, struct termios)3030-#define TCSETSF _IOW('t', 22, struct termios)3131-3232-#define TCGETA _IOR('t', 23, struct termio)3333-#define TCSETA _IOW('t', 24, struct termio)3434-#define TCSETAW _IOW('t', 25, struct termio)3535-#define TCSETAF _IOW('t', 28, struct termio)3636-3737-#define TCSBRK _IO('t', 29)3838-#define TCXONC _IO('t', 30)3939-#define TCFLSH _IO('t', 31)4040-4141-#define TIOCSWINSZ _IOW('t', 103, struct winsize)4242-#define TIOCGWINSZ _IOR('t', 104, struct winsize)4343-#define TIOCSTART _IO('t', 110) /* start output, like ^Q */4444-#define TIOCSTOP _IO('t', 111) /* stop output, like ^S */4545-#define TIOCOUTQ _IOR('t', 115, int) /* output queue size */4646-4747-#define TIOCGLTC _IOR('t', 116, struct ltchars)4848-#define TIOCSLTC _IOW('t', 117, struct ltchars)4949-#define TIOCSPGRP _IOW('t', 118, int)5050-#define TIOCGPGRP _IOR('t', 119, int)5151-5252-#define TIOCEXCL 0x540C5353-#define TIOCNXCL 0x540D5454-#define TIOCSCTTY 0x540E5555-5656-#define TIOCSTI 0x54125757-#define TIOCMGET 0x54155858-#define TIOCMBIS 0x54165959-#define TIOCMBIC 0x54176060-#define TIOCMSET 0x54186161-# define TIOCM_LE 0x0016262-# define TIOCM_DTR 0x0026363-# define TIOCM_RTS 0x0046464-# define TIOCM_ST 0x0086565-# define TIOCM_SR 0x0106666-# define TIOCM_CTS 0x0206767-# define TIOCM_CAR 0x0406868-# define TIOCM_RNG 0x0806969-# define TIOCM_DSR 0x1007070-# define TIOCM_CD TIOCM_CAR7171-# define TIOCM_RI TIOCM_RNG7272-7373-#define TIOCGSOFTCAR 0x54197474-#define TIOCSSOFTCAR 0x541A7575-#define TIOCLINUX 0x541C7676-#define TIOCCONS 0x541D7777-#define TIOCGSERIAL 0x541E7878-#define TIOCSSERIAL 0x541F7979-#define TIOCPKT 0x54208080-# define TIOCPKT_DATA 08181-# define TIOCPKT_FLUSHREAD 18282-# define TIOCPKT_FLUSHWRITE 28383-# define TIOCPKT_STOP 48484-# define TIOCPKT_START 88585-# define TIOCPKT_NOSTOP 168686-# define TIOCPKT_DOSTOP 328787-8888-8989-#define TIOCNOTTY 0x54229090-#define TIOCSETD 0x54239191-#define TIOCGETD 0x54249292-#define TCSBRKP 0x5425 /* Needed for POSIX tcsendbreak() */9393-#define TIOCSBRK 0x5427 /* BSD compatibility */9494-#define TIOCCBRK 0x5428 /* BSD compatibility */9595-#define TIOCGSID 0x5429 /* Return the session ID of FD */9696-#define TIOCGPTN _IOR('T',0x30, unsigned int) /* Get Pty Number (of pty-mux device) */9797-#define TIOCSPTLCK _IOW('T',0x31, int) /* Lock/unlock Pty */9898-9999-#define TIOCSERCONFIG 0x5453100100-#define TIOCSERGWILD 0x5454101101-#define TIOCSERSWILD 0x5455102102-#define TIOCGLCKTRMIOS 0x5456103103-#define TIOCSLCKTRMIOS 0x5457104104-#define TIOCSERGSTRUCT 0x5458 /* For debugging only */105105-#define TIOCSERGETLSR 0x5459 /* Get line status register */106106- /* ioctl (fd, TIOCSERGETLSR, &result) where result may be as below */107107-# define TIOCSER_TEMT 0x01 /* Transmitter physically empty */108108-#define TIOCSERGETMULTI 0x545A /* Get multiport config */109109-#define TIOCSERSETMULTI 0x545B /* Set multiport config */110110-111111-#define TIOCMIWAIT 0x545C /* wait for a change on serial input line(s) */112112-#define TIOCGICOUNT 0x545D /* read serial port inline interrupt counts */113113-114114-#endif /* _ASM_PPC64_IOCTLS_H */
···11-/* 22- * linux/include/asm-ppc/namei.h33- * Adapted from linux/include/asm-alpha/namei.h44- *55- * Included from linux/fs/namei.c66- *77- * This program is free software; you can redistribute it and/or88- * modify it under the terms of the GNU General Public License99- * as published by the Free Software Foundation; either version1010- * 2 of the License, or (at your option) any later version.1111- */1212-1313-#ifndef __PPC64_NAMEI_H1414-#define __PPC64_NAMEI_H1515-1616-/* This dummy routine maybe changed to something useful1717- * for /usr/gnemul/ emulation stuff.1818- * Look at asm-sparc/namei.h for details.1919- */2020-2121-#define __emul_prefix() NULL2222-2323-#endif /* __PPC64_NAMEI_H */
+3-1
include/asm-ppc64/param.h
···11#ifndef _ASM_PPC64_PARAM_H22#define _ASM_PPC64_PARAM_H3344+#include <linux/config.h>55+46/*57 * This program is free software; you can redistribute it and/or68 * modify it under the terms of the GNU General Public License···119 */12101311#ifdef __KERNEL__1414-# define HZ 1000 /* Internal kernel timer frequency */1212+# define HZ CONFIG_HZ /* Internal kernel timer frequency */1513# define USER_HZ 100 /* .. some user interfaces are in "ticks" */1614# define CLOCKS_PER_SEC (USER_HZ) /* like times() */1715#endif
···489489490490extern void paging_init(void);491491492492+#ifdef CONFIG_HUGETLB_PAGE492493#define hugetlb_free_pgd_range(tlb, addr, end, floor, ceiling) \493494 free_pgd_range(tlb, addr, end, floor, ceiling)495495+#endif494496495497/*496498 * This gets called at the end of handling a page fault, when
-32
include/asm-ppc64/poll.h
···11-#ifndef __PPC64_POLL_H22-#define __PPC64_POLL_H33-44-/*55- * Copyright (C) 2001 PPC64 Team, IBM Corp66- *77- * This program is free software; you can redistribute it and/or88- * modify it under the terms of the GNU General Public License99- * as published by the Free Software Foundation; either version1010- * 2 of the License, or (at your option) any later version.1111- */1212-1313-#define POLLIN 0x00011414-#define POLLPRI 0x00021515-#define POLLOUT 0x00041616-#define POLLERR 0x00081717-#define POLLHUP 0x00101818-#define POLLNVAL 0x00201919-#define POLLRDNORM 0x00402020-#define POLLRDBAND 0x00802121-#define POLLWRNORM 0x01002222-#define POLLWRBAND 0x02002323-#define POLLMSG 0x04002424-#define POLLREMOVE 0x10002525-2626-struct pollfd {2727- int fd;2828- short events;2929- short revents;3030-};3131-3232-#endif /* __PPC64_POLL_H */
···11-#ifndef _PPC64_SHMPARAM_H22-#define _PPC64_SHMPARAM_H33-44-/*55- * This program is free software; you can redistribute it and/or66- * modify it under the terms of the GNU General Public License77- * as published by the Free Software Foundation; either version88- * 2 of the License, or (at your option) any later version.99- */1010-1111-#define SHMLBA PAGE_SIZE /* attach addr a multiple of this */1212-1313-#endif /* _PPC64_SHMPARAM_H */
-35
include/asm-ppc64/string.h
···11-#ifndef _PPC64_STRING_H_22-#define _PPC64_STRING_H_33-44-/*55- * This program is free software; you can redistribute it and/or66- * modify it under the terms of the GNU General Public License77- * as published by the Free Software Foundation; either version88- * 2 of the License, or (at your option) any later version.99- */1010-1111-#define __HAVE_ARCH_STRCPY1212-#define __HAVE_ARCH_STRNCPY1313-#define __HAVE_ARCH_STRLEN1414-#define __HAVE_ARCH_STRCMP1515-#define __HAVE_ARCH_STRCAT1616-#define __HAVE_ARCH_MEMSET1717-#define __HAVE_ARCH_MEMCPY1818-#define __HAVE_ARCH_MEMMOVE1919-#define __HAVE_ARCH_MEMCMP2020-#define __HAVE_ARCH_MEMCHR2121-2222-extern int strcasecmp(const char *, const char *);2323-extern int strncasecmp(const char *, const char *, int);2424-extern char * strcpy(char *,const char *);2525-extern char * strncpy(char *,const char *, __kernel_size_t);2626-extern __kernel_size_t strlen(const char *);2727-extern int strcmp(const char *,const char *);2828-extern char * strcat(char *, const char *);2929-extern void * memset(void *,int,__kernel_size_t);3030-extern void * memcpy(void *,const void *,__kernel_size_t);3131-extern void * memmove(void *,const void *,__kernel_size_t);3232-extern int memcmp(const void *,const void *,__kernel_size_t);3333-extern void * memchr(const void *,int,__kernel_size_t);3434-3535-#endif /* _PPC64_STRING_H_ */
-21
include/asm-ppc64/unaligned.h
···11-#ifndef __PPC64_UNALIGNED_H22-#define __PPC64_UNALIGNED_H33-44-/*55- * The PowerPC can do unaligned accesses itself in big endian mode. 66- *77- * The strange macros are there to make sure these can't88- * be misused in a way that makes them not work on other99- * architectures where unaligned accesses aren't as simple.1010- *1111- * This program is free software; you can redistribute it and/or1212- * modify it under the terms of the GNU General Public License1313- * as published by the Free Software Foundation; either version1414- * 2 of the License, or (at your option) any later version.1515- */1616-1717-#define get_unaligned(ptr) (*(ptr))1818-1919-#define put_unaligned(val, ptr) ((void)( *(ptr) = (val) ))2020-2121-#endif /* __PPC64_UNALIGNED_H */
···11/*22 * Device tables which are exported to userspace via33- * scripts/table2alias.c. You must keep that file in sync with this33+ * scripts/mod/file2alias.c. You must keep that file in sync with this44 * header.55 */66···190190#endif191191};192192193193+/* VIO */194194+struct vio_device_id {195195+ char type[32];196196+ char compat[32];197197+};193198194199/* PCMCIA */195200
+19
scripts/mod/file2alias.c
···341341 return 1;342342}343343344344+static int do_vio_entry(const char *filename, struct vio_device_id *vio,345345+ char *alias)346346+{347347+ char *tmp;348348+349349+ sprintf(alias, "vio:T%sS%s", vio->type[0] ? vio->type : "*",350350+ vio->compat[0] ? vio->compat : "*");351351+352352+ /* Replace all whitespace with underscores */353353+ for (tmp = alias; tmp && *tmp; tmp++)354354+ if (isspace (*tmp))355355+ *tmp = '_';356356+357357+ return 1;358358+}359359+344360/* Ignore any prefix, eg. v850 prepends _ */345361static inline int sym_is(const char *symbol, const char *name)346362{···438422 else if (sym_is(symname, "__mod_of_device_table"))439423 do_table(symval, sym->st_size, sizeof(struct of_device_id),440424 do_of_entry, mod);425425+ else if (sym_is(symname, "__mod_vio_device_table"))426426+ do_table(symval, sym->st_size, sizeof(struct vio_device_id),427427+ do_vio_entry, mod);441428442429}443430