Commit d941d0ed authored by Linus Torvalds's avatar Linus Torvalds

Merge branch 'merge' of git://git.kernel.org/pub/scm/linux/kernel/git/benh/powerpc

* 'merge' of git://git.kernel.org/pub/scm/linux/kernel/git/benh/powerpc:
  powerpc/ps3: ps3_defconfig updates
  powerpc/mm: Respect _PAGE_COHERENT on classic ppc32 SW
  powerpc/5200: Enable CPU_FTR_NEED_COHERENT for MPC52xx
  ps3/block: Replace mtd/ps3vram by block/ps3vram
parents 8144737d 9aac3975
# #
# Automatically generated make config: don't edit # Automatically generated make config: don't edit
# Linux kernel version: 2.6.27-rc3 # Linux kernel version: 2.6.29-rc8
# Wed Aug 20 08:16:53 2008 # Fri Mar 13 09:28:45 2009
# #
CONFIG_PPC64=y CONFIG_PPC64=y
...@@ -16,13 +16,14 @@ CONFIG_PPC_FPU=y ...@@ -16,13 +16,14 @@ CONFIG_PPC_FPU=y
CONFIG_ALTIVEC=y CONFIG_ALTIVEC=y
# CONFIG_VSX is not set # CONFIG_VSX is not set
CONFIG_PPC_STD_MMU=y CONFIG_PPC_STD_MMU=y
CONFIG_PPC_STD_MMU_64=y
CONFIG_PPC_MM_SLICES=y CONFIG_PPC_MM_SLICES=y
CONFIG_VIRT_CPU_ACCOUNTING=y CONFIG_VIRT_CPU_ACCOUNTING=y
CONFIG_SMP=y CONFIG_SMP=y
CONFIG_NR_CPUS=2 CONFIG_NR_CPUS=2
CONFIG_64BIT=y CONFIG_64BIT=y
CONFIG_WORD_SIZE=64 CONFIG_WORD_SIZE=64
CONFIG_PPC_MERGE=y CONFIG_ARCH_PHYS_ADDR_T_64BIT=y
CONFIG_MMU=y CONFIG_MMU=y
CONFIG_GENERIC_CMOS_UPDATE=y CONFIG_GENERIC_CMOS_UPDATE=y
CONFIG_GENERIC_TIME=y CONFIG_GENERIC_TIME=y
...@@ -46,7 +47,7 @@ CONFIG_PPC=y ...@@ -46,7 +47,7 @@ CONFIG_PPC=y
CONFIG_EARLY_PRINTK=y CONFIG_EARLY_PRINTK=y
CONFIG_COMPAT=y CONFIG_COMPAT=y
CONFIG_SYSVIPC_COMPAT=y CONFIG_SYSVIPC_COMPAT=y
CONFIG_SCHED_NO_NO_OMIT_FRAME_POINTER=y CONFIG_SCHED_OMIT_FRAME_POINTER=y
CONFIG_ARCH_MAY_HAVE_PC_FDC=y CONFIG_ARCH_MAY_HAVE_PC_FDC=y
CONFIG_PPC_OF=y CONFIG_PPC_OF=y
CONFIG_OF=y CONFIG_OF=y
...@@ -74,10 +75,19 @@ CONFIG_POSIX_MQUEUE=y ...@@ -74,10 +75,19 @@ CONFIG_POSIX_MQUEUE=y
# CONFIG_BSD_PROCESS_ACCT is not set # CONFIG_BSD_PROCESS_ACCT is not set
# CONFIG_TASKSTATS is not set # CONFIG_TASKSTATS is not set
# CONFIG_AUDIT is not set # CONFIG_AUDIT is not set
#
# RCU Subsystem
#
CONFIG_CLASSIC_RCU=y
# CONFIG_TREE_RCU is not set
# CONFIG_PREEMPT_RCU is not set
# CONFIG_TREE_RCU_TRACE is not set
# CONFIG_PREEMPT_RCU_TRACE is not set
# CONFIG_IKCONFIG is not set # CONFIG_IKCONFIG is not set
CONFIG_LOG_BUF_SHIFT=17 CONFIG_LOG_BUF_SHIFT=17
# CONFIG_CGROUPS is not set
# CONFIG_GROUP_SCHED is not set # CONFIG_GROUP_SCHED is not set
# CONFIG_CGROUPS is not set
CONFIG_SYSFS_DEPRECATED=y CONFIG_SYSFS_DEPRECATED=y
CONFIG_SYSFS_DEPRECATED_V2=y CONFIG_SYSFS_DEPRECATED_V2=y
# CONFIG_RELAY is not set # CONFIG_RELAY is not set
...@@ -86,11 +96,13 @@ CONFIG_NAMESPACES=y ...@@ -86,11 +96,13 @@ CONFIG_NAMESPACES=y
# CONFIG_IPC_NS is not set # CONFIG_IPC_NS is not set
# CONFIG_USER_NS is not set # CONFIG_USER_NS is not set
# CONFIG_PID_NS is not set # CONFIG_PID_NS is not set
# CONFIG_NET_NS is not set
CONFIG_BLK_DEV_INITRD=y CONFIG_BLK_DEV_INITRD=y
CONFIG_INITRAMFS_SOURCE="" CONFIG_INITRAMFS_SOURCE=""
CONFIG_CC_OPTIMIZE_FOR_SIZE=y CONFIG_CC_OPTIMIZE_FOR_SIZE=y
CONFIG_SYSCTL=y CONFIG_SYSCTL=y
# CONFIG_EMBEDDED is not set CONFIG_ANON_INODES=y
CONFIG_EMBEDDED=y
CONFIG_SYSCTL_SYSCALL=y CONFIG_SYSCTL_SYSCALL=y
CONFIG_KALLSYMS=y CONFIG_KALLSYMS=y
CONFIG_KALLSYMS_ALL=y CONFIG_KALLSYMS_ALL=y
...@@ -99,37 +111,36 @@ CONFIG_HOTPLUG=y ...@@ -99,37 +111,36 @@ CONFIG_HOTPLUG=y
CONFIG_PRINTK=y CONFIG_PRINTK=y
CONFIG_BUG=y CONFIG_BUG=y
CONFIG_ELF_CORE=y CONFIG_ELF_CORE=y
# CONFIG_COMPAT_BRK is not set
CONFIG_BASE_FULL=y CONFIG_BASE_FULL=y
CONFIG_FUTEX=y CONFIG_FUTEX=y
CONFIG_ANON_INODES=y
CONFIG_EPOLL=y CONFIG_EPOLL=y
CONFIG_SIGNALFD=y CONFIG_SIGNALFD=y
CONFIG_TIMERFD=y CONFIG_TIMERFD=y
CONFIG_EVENTFD=y CONFIG_EVENTFD=y
CONFIG_SHMEM=y CONFIG_SHMEM=y
CONFIG_AIO=y
CONFIG_VM_EVENT_COUNTERS=y CONFIG_VM_EVENT_COUNTERS=y
# CONFIG_COMPAT_BRK is not set
CONFIG_SLAB=y CONFIG_SLAB=y
# CONFIG_SLUB is not set # CONFIG_SLUB is not set
# CONFIG_SLOB is not set # CONFIG_SLOB is not set
CONFIG_PROFILING=y CONFIG_PROFILING=y
# CONFIG_MARKERS is not set CONFIG_TRACEPOINTS=y
CONFIG_MARKERS=y
CONFIG_OPROFILE=m CONFIG_OPROFILE=m
CONFIG_HAVE_OPROFILE=y CONFIG_HAVE_OPROFILE=y
# CONFIG_KPROBES is not set # CONFIG_KPROBES is not set
CONFIG_HAVE_EFFICIENT_UNALIGNED_ACCESS=y CONFIG_HAVE_EFFICIENT_UNALIGNED_ACCESS=y
CONFIG_HAVE_SYSCALL_WRAPPERS=y
CONFIG_HAVE_IOREMAP_PROT=y CONFIG_HAVE_IOREMAP_PROT=y
CONFIG_HAVE_KPROBES=y CONFIG_HAVE_KPROBES=y
CONFIG_HAVE_KRETPROBES=y CONFIG_HAVE_KRETPROBES=y
CONFIG_HAVE_ARCH_TRACEHOOK=y CONFIG_HAVE_ARCH_TRACEHOOK=y
CONFIG_HAVE_DMA_ATTRS=y CONFIG_HAVE_DMA_ATTRS=y
CONFIG_USE_GENERIC_SMP_HELPERS=y CONFIG_USE_GENERIC_SMP_HELPERS=y
# CONFIG_HAVE_CLK is not set
CONFIG_PROC_PAGE_MONITOR=y
# CONFIG_HAVE_GENERIC_DMA_COHERENT is not set # CONFIG_HAVE_GENERIC_DMA_COHERENT is not set
CONFIG_SLABINFO=y CONFIG_SLABINFO=y
CONFIG_RT_MUTEXES=y CONFIG_RT_MUTEXES=y
# CONFIG_TINY_SHMEM is not set
CONFIG_BASE_SMALL=0 CONFIG_BASE_SMALL=0
CONFIG_MODULES=y CONFIG_MODULES=y
# CONFIG_MODULE_FORCE_LOAD is not set # CONFIG_MODULE_FORCE_LOAD is not set
...@@ -137,7 +148,6 @@ CONFIG_MODULE_UNLOAD=y ...@@ -137,7 +148,6 @@ CONFIG_MODULE_UNLOAD=y
# CONFIG_MODULE_FORCE_UNLOAD is not set # CONFIG_MODULE_FORCE_UNLOAD is not set
# CONFIG_MODVERSIONS is not set # CONFIG_MODVERSIONS is not set
# CONFIG_MODULE_SRCVERSION_ALL is not set # CONFIG_MODULE_SRCVERSION_ALL is not set
CONFIG_KMOD=y
CONFIG_STOP_MACHINE=y CONFIG_STOP_MACHINE=y
CONFIG_BLOCK=y CONFIG_BLOCK=y
# CONFIG_BLK_DEV_IO_TRACE is not set # CONFIG_BLK_DEV_IO_TRACE is not set
...@@ -157,7 +167,7 @@ CONFIG_DEFAULT_AS=y ...@@ -157,7 +167,7 @@ CONFIG_DEFAULT_AS=y
# CONFIG_DEFAULT_CFQ is not set # CONFIG_DEFAULT_CFQ is not set
# CONFIG_DEFAULT_NOOP is not set # CONFIG_DEFAULT_NOOP is not set
CONFIG_DEFAULT_IOSCHED="anticipatory" CONFIG_DEFAULT_IOSCHED="anticipatory"
CONFIG_CLASSIC_RCU=y # CONFIG_FREEZER is not set
# #
# Platform support # Platform support
...@@ -183,18 +193,20 @@ CONFIG_PS3_STORAGE=y ...@@ -183,18 +193,20 @@ CONFIG_PS3_STORAGE=y
CONFIG_PS3_DISK=y CONFIG_PS3_DISK=y
CONFIG_PS3_ROM=y CONFIG_PS3_ROM=y
CONFIG_PS3_FLASH=y CONFIG_PS3_FLASH=y
CONFIG_OPROFILE_PS3=y CONFIG_PS3_VRAM=m
CONFIG_PS3_LPM=m CONFIG_PS3_LPM=m
CONFIG_PPC_CELL=y CONFIG_PPC_CELL=y
# CONFIG_PPC_CELL_NATIVE is not set # CONFIG_PPC_CELL_NATIVE is not set
# CONFIG_PPC_IBM_CELL_BLADE is not set # CONFIG_PPC_IBM_CELL_BLADE is not set
# CONFIG_PPC_CELLEB is not set # CONFIG_PPC_CELLEB is not set
# CONFIG_PPC_CELL_QPACE is not set
# #
# Cell Broadband Engine options # Cell Broadband Engine options
# #
CONFIG_SPU_FS=y CONFIG_SPU_FS=y
CONFIG_SPU_FS_64K_LS=y CONFIG_SPU_FS_64K_LS=y
# CONFIG_SPU_TRACE is not set
CONFIG_SPU_BASE=y CONFIG_SPU_BASE=y
# CONFIG_PQ2ADS is not set # CONFIG_PQ2ADS is not set
# CONFIG_IPIC is not set # CONFIG_IPIC is not set
...@@ -210,6 +222,7 @@ CONFIG_SPU_BASE=y ...@@ -210,6 +222,7 @@ CONFIG_SPU_BASE=y
# CONFIG_GENERIC_IOMAP is not set # CONFIG_GENERIC_IOMAP is not set
# CONFIG_CPU_FREQ is not set # CONFIG_CPU_FREQ is not set
# CONFIG_FSL_ULI1575 is not set # CONFIG_FSL_ULI1575 is not set
# CONFIG_SIMPLE_GPIO is not set
# #
# Kernel options # Kernel options
...@@ -229,6 +242,8 @@ CONFIG_PREEMPT_NONE=y ...@@ -229,6 +242,8 @@ CONFIG_PREEMPT_NONE=y
# CONFIG_PREEMPT is not set # CONFIG_PREEMPT is not set
CONFIG_BINFMT_ELF=y CONFIG_BINFMT_ELF=y
CONFIG_COMPAT_BINFMT_ELF=y CONFIG_COMPAT_BINFMT_ELF=y
# CONFIG_CORE_DUMP_DEFAULT_ELF_HEADERS is not set
# CONFIG_HAVE_AOUT is not set
CONFIG_BINFMT_MISC=y CONFIG_BINFMT_MISC=y
CONFIG_HUGETLB_PAGE_SIZE_VARIABLE=y CONFIG_HUGETLB_PAGE_SIZE_VARIABLE=y
# CONFIG_IOMMU_VMERGE is not set # CONFIG_IOMMU_VMERGE is not set
...@@ -251,7 +266,6 @@ CONFIG_SELECT_MEMORY_MODEL=y ...@@ -251,7 +266,6 @@ CONFIG_SELECT_MEMORY_MODEL=y
CONFIG_SPARSEMEM_MANUAL=y CONFIG_SPARSEMEM_MANUAL=y
CONFIG_SPARSEMEM=y CONFIG_SPARSEMEM=y
CONFIG_HAVE_MEMORY_PRESENT=y CONFIG_HAVE_MEMORY_PRESENT=y
# CONFIG_SPARSEMEM_STATIC is not set
CONFIG_SPARSEMEM_EXTREME=y CONFIG_SPARSEMEM_EXTREME=y
CONFIG_SPARSEMEM_VMEMMAP_ENABLE=y CONFIG_SPARSEMEM_VMEMMAP_ENABLE=y
# CONFIG_SPARSEMEM_VMEMMAP is not set # CONFIG_SPARSEMEM_VMEMMAP is not set
...@@ -261,11 +275,14 @@ CONFIG_MEMORY_HOTPLUG_SPARSE=y ...@@ -261,11 +275,14 @@ CONFIG_MEMORY_HOTPLUG_SPARSE=y
CONFIG_PAGEFLAGS_EXTENDED=y CONFIG_PAGEFLAGS_EXTENDED=y
CONFIG_SPLIT_PTLOCK_CPUS=4 CONFIG_SPLIT_PTLOCK_CPUS=4
CONFIG_MIGRATION=y CONFIG_MIGRATION=y
CONFIG_RESOURCES_64BIT=y CONFIG_PHYS_ADDR_T_64BIT=y
CONFIG_ZONE_DMA_FLAG=1 CONFIG_ZONE_DMA_FLAG=1
CONFIG_BOUNCE=y CONFIG_BOUNCE=y
CONFIG_UNEVICTABLE_LRU=y
CONFIG_ARCH_MEMORY_PROBE=y CONFIG_ARCH_MEMORY_PROBE=y
CONFIG_PPC_HAS_HASH_64K=y CONFIG_PPC_HAS_HASH_64K=y
CONFIG_PPC_4K_PAGES=y
# CONFIG_PPC_16K_PAGES is not set
# CONFIG_PPC_64K_PAGES is not set # CONFIG_PPC_64K_PAGES is not set
CONFIG_FORCE_MAX_ZONEORDER=13 CONFIG_FORCE_MAX_ZONEORDER=13
CONFIG_SCHED_SMT=y CONFIG_SCHED_SMT=y
...@@ -299,6 +316,7 @@ CONFIG_NET=y ...@@ -299,6 +316,7 @@ CONFIG_NET=y
# #
# Networking options # Networking options
# #
CONFIG_COMPAT_NET_DEV_OPS=y
CONFIG_PACKET=y CONFIG_PACKET=y
CONFIG_PACKET_MMAP=y CONFIG_PACKET_MMAP=y
CONFIG_UNIX=y CONFIG_UNIX=y
...@@ -361,6 +379,7 @@ CONFIG_IPV6_NDISC_NODETYPE=y ...@@ -361,6 +379,7 @@ CONFIG_IPV6_NDISC_NODETYPE=y
# CONFIG_TIPC is not set # CONFIG_TIPC is not set
# CONFIG_ATM is not set # CONFIG_ATM is not set
# CONFIG_BRIDGE is not set # CONFIG_BRIDGE is not set
# CONFIG_NET_DSA is not set
# CONFIG_VLAN_8021Q is not set # CONFIG_VLAN_8021Q is not set
# CONFIG_DECNET is not set # CONFIG_DECNET is not set
# CONFIG_LLC2 is not set # CONFIG_LLC2 is not set
...@@ -371,6 +390,7 @@ CONFIG_IPV6_NDISC_NODETYPE=y ...@@ -371,6 +390,7 @@ CONFIG_IPV6_NDISC_NODETYPE=y
# CONFIG_ECONET is not set # CONFIG_ECONET is not set
# CONFIG_WAN_ROUTER is not set # CONFIG_WAN_ROUTER is not set
# CONFIG_NET_SCHED is not set # CONFIG_NET_SCHED is not set
# CONFIG_DCB is not set
# #
# Network testing # Network testing
...@@ -392,39 +412,37 @@ CONFIG_BT_HIDP=m ...@@ -392,39 +412,37 @@ CONFIG_BT_HIDP=m
# #
# Bluetooth device drivers # Bluetooth device drivers
# #
CONFIG_BT_HCIUSB=m CONFIG_BT_HCIBTUSB=m
CONFIG_BT_HCIUSB_SCO=y
# CONFIG_BT_HCIUART is not set # CONFIG_BT_HCIUART is not set
# CONFIG_BT_HCIBCM203X is not set # CONFIG_BT_HCIBCM203X is not set
# CONFIG_BT_HCIBPA10X is not set # CONFIG_BT_HCIBPA10X is not set
# CONFIG_BT_HCIBFUSB is not set # CONFIG_BT_HCIBFUSB is not set
# CONFIG_BT_HCIVHCI is not set # CONFIG_BT_HCIVHCI is not set
# CONFIG_AF_RXRPC is not set # CONFIG_AF_RXRPC is not set
# CONFIG_PHONET is not set
# CONFIG_WIRELESS=y
# Wireless
#
CONFIG_CFG80211=m CONFIG_CFG80211=m
# CONFIG_CFG80211_REG_DEBUG is not set
CONFIG_NL80211=y CONFIG_NL80211=y
# CONFIG_WIRELESS_OLD_REGULATORY is not set
CONFIG_WIRELESS_EXT=y CONFIG_WIRELESS_EXT=y
# CONFIG_WIRELESS_EXT_SYSFS is not set # CONFIG_WIRELESS_EXT_SYSFS is not set
# CONFIG_LIB80211 is not set
CONFIG_MAC80211=m CONFIG_MAC80211=m
# #
# Rate control algorithm selection # Rate control algorithm selection
# #
CONFIG_MAC80211_RC_PID=y CONFIG_MAC80211_RC_PID=y
# CONFIG_MAC80211_RC_MINSTREL is not set
CONFIG_MAC80211_RC_DEFAULT_PID=y CONFIG_MAC80211_RC_DEFAULT_PID=y
# CONFIG_MAC80211_RC_DEFAULT_MINSTREL is not set
CONFIG_MAC80211_RC_DEFAULT="pid" CONFIG_MAC80211_RC_DEFAULT="pid"
# CONFIG_MAC80211_MESH is not set # CONFIG_MAC80211_MESH is not set
# CONFIG_MAC80211_LEDS is not set # CONFIG_MAC80211_LEDS is not set
# CONFIG_MAC80211_DEBUGFS is not set # CONFIG_MAC80211_DEBUGFS is not set
# CONFIG_MAC80211_DEBUG_MENU is not set # CONFIG_MAC80211_DEBUG_MENU is not set
CONFIG_IEEE80211=m # CONFIG_WIMAX is not set
# CONFIG_IEEE80211_DEBUG is not set
CONFIG_IEEE80211_CRYPT_WEP=m
CONFIG_IEEE80211_CRYPT_CCMP=m
CONFIG_IEEE80211_CRYPT_TKIP=m
# CONFIG_RFKILL is not set # CONFIG_RFKILL is not set
# CONFIG_NET_9P is not set # CONFIG_NET_9P is not set
...@@ -450,6 +468,7 @@ CONFIG_MTD_DEBUG=y ...@@ -450,6 +468,7 @@ CONFIG_MTD_DEBUG=y
CONFIG_MTD_DEBUG_VERBOSE=0 CONFIG_MTD_DEBUG_VERBOSE=0
# CONFIG_MTD_CONCAT is not set # CONFIG_MTD_CONCAT is not set
# CONFIG_MTD_PARTITIONS is not set # CONFIG_MTD_PARTITIONS is not set
# CONFIG_MTD_TESTS is not set
# #
# User Modules And Translation Layers # User Modules And Translation Layers
...@@ -494,7 +513,6 @@ CONFIG_MTD_CFI_I2=y ...@@ -494,7 +513,6 @@ CONFIG_MTD_CFI_I2=y
# #
# CONFIG_MTD_SLRAM is not set # CONFIG_MTD_SLRAM is not set
# CONFIG_MTD_PHRAM is not set # CONFIG_MTD_PHRAM is not set
CONFIG_MTD_PS3VRAM=y
# CONFIG_MTD_MTDRAM is not set # CONFIG_MTD_MTDRAM is not set
# CONFIG_MTD_BLOCK2MTD is not set # CONFIG_MTD_BLOCK2MTD is not set
...@@ -507,6 +525,11 @@ CONFIG_MTD_PS3VRAM=y ...@@ -507,6 +525,11 @@ CONFIG_MTD_PS3VRAM=y
# CONFIG_MTD_NAND is not set # CONFIG_MTD_NAND is not set
# CONFIG_MTD_ONENAND is not set # CONFIG_MTD_ONENAND is not set
#
# LPDDR flash memory drivers
#
# CONFIG_MTD_LPDDR is not set
# #
# UBI - Unsorted block images # UBI - Unsorted block images
# #
...@@ -528,8 +551,13 @@ CONFIG_BLK_DEV_RAM_SIZE=65535 ...@@ -528,8 +551,13 @@ CONFIG_BLK_DEV_RAM_SIZE=65535
# CONFIG_ATA_OVER_ETH is not set # CONFIG_ATA_OVER_ETH is not set
# CONFIG_BLK_DEV_HD is not set # CONFIG_BLK_DEV_HD is not set
CONFIG_MISC_DEVICES=y CONFIG_MISC_DEVICES=y
# CONFIG_EEPROM_93CX6 is not set
# CONFIG_ENCLOSURE_SERVICES is not set # CONFIG_ENCLOSURE_SERVICES is not set
# CONFIG_C2PORT is not set
#
# EEPROM support
#
# CONFIG_EEPROM_93CX6 is not set
CONFIG_HAVE_IDE=y CONFIG_HAVE_IDE=y
# CONFIG_IDE is not set # CONFIG_IDE is not set
...@@ -575,7 +603,17 @@ CONFIG_SCSI_WAIT_SCAN=m ...@@ -575,7 +603,17 @@ CONFIG_SCSI_WAIT_SCAN=m
# CONFIG_SCSI_LOWLEVEL is not set # CONFIG_SCSI_LOWLEVEL is not set
# CONFIG_SCSI_DH is not set # CONFIG_SCSI_DH is not set
# CONFIG_ATA is not set # CONFIG_ATA is not set
# CONFIG_MD is not set CONFIG_MD=y
# CONFIG_BLK_DEV_MD is not set
CONFIG_BLK_DEV_DM=m
# CONFIG_DM_DEBUG is not set
# CONFIG_DM_CRYPT is not set
# CONFIG_DM_SNAPSHOT is not set
# CONFIG_DM_MIRROR is not set
# CONFIG_DM_ZERO is not set
# CONFIG_DM_MULTIPATH is not set
# CONFIG_DM_DELAY is not set
# CONFIG_DM_UEVENT is not set
# CONFIG_MACINTOSH_DRIVERS is not set # CONFIG_MACINTOSH_DRIVERS is not set
CONFIG_NETDEVICES=y CONFIG_NETDEVICES=y
# CONFIG_DUMMY is not set # CONFIG_DUMMY is not set
...@@ -591,6 +629,9 @@ CONFIG_MII=m ...@@ -591,6 +629,9 @@ CONFIG_MII=m
# CONFIG_IBM_NEW_EMAC_RGMII is not set # CONFIG_IBM_NEW_EMAC_RGMII is not set
# CONFIG_IBM_NEW_EMAC_TAH is not set # CONFIG_IBM_NEW_EMAC_TAH is not set
# CONFIG_IBM_NEW_EMAC_EMAC4 is not set # CONFIG_IBM_NEW_EMAC_EMAC4 is not set
# CONFIG_IBM_NEW_EMAC_NO_FLOW_CTRL is not set
# CONFIG_IBM_NEW_EMAC_MAL_CLR_ICINTSTAT is not set
# CONFIG_IBM_NEW_EMAC_MAL_COMMON_ERR is not set
# CONFIG_B44 is not set # CONFIG_B44 is not set
CONFIG_NETDEV_1000=y CONFIG_NETDEV_1000=y
CONFIG_GELIC_NET=y CONFIG_GELIC_NET=y
...@@ -604,6 +645,7 @@ CONFIG_GELIC_WIRELESS_OLD_PSK_INTERFACE=y ...@@ -604,6 +645,7 @@ CONFIG_GELIC_WIRELESS_OLD_PSK_INTERFACE=y
# CONFIG_WLAN_PRE80211 is not set # CONFIG_WLAN_PRE80211 is not set
CONFIG_WLAN_80211=y CONFIG_WLAN_80211=y
# CONFIG_LIBERTAS is not set # CONFIG_LIBERTAS is not set
# CONFIG_LIBERTAS_THINFIRM is not set
# CONFIG_USB_ZD1201 is not set # CONFIG_USB_ZD1201 is not set
# CONFIG_USB_NET_RNDIS_WLAN is not set # CONFIG_USB_NET_RNDIS_WLAN is not set
# CONFIG_RTL8187 is not set # CONFIG_RTL8187 is not set
...@@ -615,13 +657,11 @@ CONFIG_WLAN_80211=y ...@@ -615,13 +657,11 @@ CONFIG_WLAN_80211=y
# CONFIG_B43LEGACY is not set # CONFIG_B43LEGACY is not set
CONFIG_ZD1211RW=m CONFIG_ZD1211RW=m
# CONFIG_ZD1211RW_DEBUG is not set # CONFIG_ZD1211RW_DEBUG is not set
CONFIG_RT2X00=m # CONFIG_RT2X00 is not set
CONFIG_RT2X00_LIB=m
CONFIG_RT2X00_LIB_USB=m #
CONFIG_RT2X00_LIB_FIRMWARE=y # Enable WiMAX (Networking options) to see the WiMAX drivers
# CONFIG_RT2500USB is not set #
CONFIG_RT73USB=m
# CONFIG_RT2X00_DEBUG is not set
# #
# USB Network Adapters # USB Network Adapters
...@@ -634,6 +674,7 @@ CONFIG_USB_USBNET=m ...@@ -634,6 +674,7 @@ CONFIG_USB_USBNET=m
CONFIG_USB_NET_AX8817X=m CONFIG_USB_NET_AX8817X=m
# CONFIG_USB_NET_CDCETHER is not set # CONFIG_USB_NET_CDCETHER is not set
# CONFIG_USB_NET_DM9601 is not set # CONFIG_USB_NET_DM9601 is not set
# CONFIG_USB_NET_SMSC95XX is not set
# CONFIG_USB_NET_GL620A is not set # CONFIG_USB_NET_GL620A is not set
# CONFIG_USB_NET_NET1080 is not set # CONFIG_USB_NET_NET1080 is not set
# CONFIG_USB_NET_PLUSB is not set # CONFIG_USB_NET_PLUSB is not set
...@@ -664,7 +705,7 @@ CONFIG_SLHC=m ...@@ -664,7 +705,7 @@ CONFIG_SLHC=m
# Input device support # Input device support
# #
CONFIG_INPUT=y CONFIG_INPUT=y
# CONFIG_INPUT_FF_MEMLESS is not set CONFIG_INPUT_FF_MEMLESS=m
# CONFIG_INPUT_POLLDEV is not set # CONFIG_INPUT_POLLDEV is not set
# #
...@@ -735,8 +776,10 @@ CONFIG_DEVKMEM=y ...@@ -735,8 +776,10 @@ CONFIG_DEVKMEM=y
# Non-8250 serial port support # Non-8250 serial port support
# #
CONFIG_UNIX98_PTYS=y CONFIG_UNIX98_PTYS=y
# CONFIG_DEVPTS_MULTIPLE_INSTANCES is not set
CONFIG_LEGACY_PTYS=y CONFIG_LEGACY_PTYS=y
CONFIG_LEGACY_PTY_COUNT=16 CONFIG_LEGACY_PTY_COUNT=16
# CONFIG_HVC_UDBG is not set
# CONFIG_IPMI_HANDLER is not set # CONFIG_IPMI_HANDLER is not set
# CONFIG_HW_RANDOM is not set # CONFIG_HW_RANDOM is not set
# CONFIG_R3964 is not set # CONFIG_R3964 is not set
...@@ -753,11 +796,11 @@ CONFIG_ARCH_WANT_OPTIONAL_GPIOLIB=y ...@@ -753,11 +796,11 @@ CONFIG_ARCH_WANT_OPTIONAL_GPIOLIB=y
# CONFIG_THERMAL is not set # CONFIG_THERMAL is not set
# CONFIG_THERMAL_HWMON is not set # CONFIG_THERMAL_HWMON is not set
# CONFIG_WATCHDOG is not set # CONFIG_WATCHDOG is not set
CONFIG_SSB_POSSIBLE=y
# #
# Sonics Silicon Backplane # Sonics Silicon Backplane
# #
CONFIG_SSB_POSSIBLE=y
# CONFIG_SSB is not set # CONFIG_SSB is not set
# #
...@@ -767,6 +810,7 @@ CONFIG_SSB_POSSIBLE=y ...@@ -767,6 +810,7 @@ CONFIG_SSB_POSSIBLE=y
# CONFIG_MFD_SM501 is not set # CONFIG_MFD_SM501 is not set
# CONFIG_HTC_PASIC3 is not set # CONFIG_HTC_PASIC3 is not set
# CONFIG_MFD_TMIO is not set # CONFIG_MFD_TMIO is not set
# CONFIG_REGULATOR is not set
# #
# Multimedia devices # Multimedia devices
...@@ -792,6 +836,7 @@ CONFIG_VIDEO_OUTPUT_CONTROL=m ...@@ -792,6 +836,7 @@ CONFIG_VIDEO_OUTPUT_CONTROL=m
CONFIG_FB=y CONFIG_FB=y
# CONFIG_FIRMWARE_EDID is not set # CONFIG_FIRMWARE_EDID is not set
# CONFIG_FB_DDC is not set # CONFIG_FB_DDC is not set
# CONFIG_FB_BOOT_VESA_SUPPORT is not set
# CONFIG_FB_CFB_FILLRECT is not set # CONFIG_FB_CFB_FILLRECT is not set
# CONFIG_FB_CFB_COPYAREA is not set # CONFIG_FB_CFB_COPYAREA is not set
# CONFIG_FB_CFB_IMAGEBLIT is not set # CONFIG_FB_CFB_IMAGEBLIT is not set
...@@ -817,6 +862,8 @@ CONFIG_FB_SYS_FOPS=y ...@@ -817,6 +862,8 @@ CONFIG_FB_SYS_FOPS=y
CONFIG_FB_PS3=y CONFIG_FB_PS3=y
CONFIG_FB_PS3_DEFAULT_SIZE_M=9 CONFIG_FB_PS3_DEFAULT_SIZE_M=9
# CONFIG_FB_VIRTUAL is not set # CONFIG_FB_VIRTUAL is not set
# CONFIG_FB_METRONOME is not set
# CONFIG_FB_MB862XX is not set
# CONFIG_BACKLIGHT_LCD_SUPPORT is not set # CONFIG_BACKLIGHT_LCD_SUPPORT is not set
# #
...@@ -841,6 +888,7 @@ CONFIG_FB_LOGO_EXTRA=y ...@@ -841,6 +888,7 @@ CONFIG_FB_LOGO_EXTRA=y
# CONFIG_LOGO_LINUX_VGA16 is not set # CONFIG_LOGO_LINUX_VGA16 is not set
CONFIG_LOGO_LINUX_CLUT224=y CONFIG_LOGO_LINUX_CLUT224=y
CONFIG_SOUND=m CONFIG_SOUND=m
# CONFIG_SOUND_OSS_CORE is not set
CONFIG_SND=m CONFIG_SND=m
CONFIG_SND_TIMER=m CONFIG_SND_TIMER=m
CONFIG_SND_PCM=m CONFIG_SND_PCM=m
...@@ -849,6 +897,7 @@ CONFIG_SND_RAWMIDI=m ...@@ -849,6 +897,7 @@ CONFIG_SND_RAWMIDI=m
# CONFIG_SND_SEQUENCER is not set # CONFIG_SND_SEQUENCER is not set
# CONFIG_SND_MIXER_OSS is not set # CONFIG_SND_MIXER_OSS is not set
# CONFIG_SND_PCM_OSS is not set # CONFIG_SND_PCM_OSS is not set
# CONFIG_SND_HRTIMER is not set
# CONFIG_SND_DYNAMIC_MINORS is not set # CONFIG_SND_DYNAMIC_MINORS is not set
CONFIG_SND_SUPPORT_OLD_API=y CONFIG_SND_SUPPORT_OLD_API=y
CONFIG_SND_VERBOSE_PROCFS=y CONFIG_SND_VERBOSE_PROCFS=y
...@@ -873,15 +922,40 @@ CONFIG_HIDRAW=y ...@@ -873,15 +922,40 @@ CONFIG_HIDRAW=y
# USB Input Devices # USB Input Devices
# #
CONFIG_USB_HID=m CONFIG_USB_HID=m
# CONFIG_USB_HIDINPUT_POWERBOOK is not set # CONFIG_HID_PID is not set
# CONFIG_HID_FF is not set CONFIG_USB_HIDDEV=y
# CONFIG_USB_HIDDEV is not set
# #
# USB HID Boot Protocol drivers # USB HID Boot Protocol drivers
# #
# CONFIG_USB_KBD is not set # CONFIG_USB_KBD is not set
# CONFIG_USB_MOUSE is not set # CONFIG_USB_MOUSE is not set
#
# Special HID drivers
#
# CONFIG_HID_COMPAT is not set
# CONFIG_HID_A4TECH is not set
# CONFIG_HID_APPLE is not set
# CONFIG_HID_BELKIN is not set
# CONFIG_HID_CHERRY is not set
# CONFIG_HID_CHICONY is not set
# CONFIG_HID_CYPRESS is not set
# CONFIG_HID_EZKEY is not set
# CONFIG_HID_GYRATION is not set
# CONFIG_HID_LOGITECH is not set
# CONFIG_HID_MICROSOFT is not set
# CONFIG_HID_MONTEREY is not set
# CONFIG_HID_NTRIG is not set
# CONFIG_HID_PANTHERLORD is not set
# CONFIG_HID_PETALYNX is not set
# CONFIG_HID_SAMSUNG is not set
# CONFIG_HID_SONY is not set
# CONFIG_HID_SUNPLUS is not set
# CONFIG_GREENASIA_FF is not set
# CONFIG_HID_TOPSEED is not set
# CONFIG_THRUSTMASTER_FF is not set
# CONFIG_ZEROPLUS_FF is not set
CONFIG_USB_SUPPORT=y CONFIG_USB_SUPPORT=y
CONFIG_USB_ARCH_HAS_HCD=y CONFIG_USB_ARCH_HAS_HCD=y
CONFIG_USB_ARCH_HAS_OHCI=y CONFIG_USB_ARCH_HAS_OHCI=y
...@@ -898,7 +972,11 @@ CONFIG_USB_DEVICEFS=y ...@@ -898,7 +972,11 @@ CONFIG_USB_DEVICEFS=y
# CONFIG_USB_DYNAMIC_MINORS is not set # CONFIG_USB_DYNAMIC_MINORS is not set
CONFIG_USB_SUSPEND=y CONFIG_USB_SUSPEND=y
# CONFIG_USB_OTG is not set # CONFIG_USB_OTG is not set
CONFIG_USB_MON=y # CONFIG_USB_OTG_WHITELIST is not set
# CONFIG_USB_OTG_BLACKLIST_HUB is not set
CONFIG_USB_MON=m
# CONFIG_USB_WUSB is not set
# CONFIG_USB_WUSB_CBAF is not set
# #
# USB Host Controller Drivers # USB Host Controller Drivers
...@@ -909,6 +987,7 @@ CONFIG_USB_EHCI_HCD=m ...@@ -909,6 +987,7 @@ CONFIG_USB_EHCI_HCD=m
# CONFIG_USB_EHCI_TT_NEWSCHED is not set # CONFIG_USB_EHCI_TT_NEWSCHED is not set
CONFIG_USB_EHCI_BIG_ENDIAN_MMIO=y CONFIG_USB_EHCI_BIG_ENDIAN_MMIO=y
# CONFIG_USB_EHCI_HCD_PPC_OF is not set # CONFIG_USB_EHCI_HCD_PPC_OF is not set
# CONFIG_USB_OXU210HP_HCD is not set
# CONFIG_USB_ISP116X_HCD is not set # CONFIG_USB_ISP116X_HCD is not set
# CONFIG_USB_ISP1760_HCD is not set # CONFIG_USB_ISP1760_HCD is not set
CONFIG_USB_OHCI_HCD=m CONFIG_USB_OHCI_HCD=m
...@@ -918,6 +997,7 @@ CONFIG_USB_OHCI_BIG_ENDIAN_MMIO=y ...@@ -918,6 +997,7 @@ CONFIG_USB_OHCI_BIG_ENDIAN_MMIO=y
CONFIG_USB_OHCI_LITTLE_ENDIAN=y CONFIG_USB_OHCI_LITTLE_ENDIAN=y
# CONFIG_USB_SL811_HCD is not set # CONFIG_USB_SL811_HCD is not set
# CONFIG_USB_R8A66597_HCD is not set # CONFIG_USB_R8A66597_HCD is not set
# CONFIG_USB_HWA_HCD is not set
# #
# Enable Host or Gadget support to see Inventra options # Enable Host or Gadget support to see Inventra options
...@@ -929,20 +1009,20 @@ CONFIG_USB_OHCI_LITTLE_ENDIAN=y ...@@ -929,20 +1009,20 @@ CONFIG_USB_OHCI_LITTLE_ENDIAN=y
# CONFIG_USB_ACM is not set # CONFIG_USB_ACM is not set
# CONFIG_USB_PRINTER is not set # CONFIG_USB_PRINTER is not set
# CONFIG_USB_WDM is not set # CONFIG_USB_WDM is not set
# CONFIG_USB_TMC is not set
# #
# NOTE: USB_STORAGE enables SCSI, and 'SCSI disk support' # NOTE: USB_STORAGE depends on SCSI but BLK_DEV_SD may also be needed;
# #
# #
# may also be needed; see USB_STORAGE Help for more information # see USB_STORAGE Help for more information
# #
CONFIG_USB_STORAGE=m CONFIG_USB_STORAGE=m
# CONFIG_USB_STORAGE_DEBUG is not set # CONFIG_USB_STORAGE_DEBUG is not set
# CONFIG_USB_STORAGE_DATAFAB is not set # CONFIG_USB_STORAGE_DATAFAB is not set
# CONFIG_USB_STORAGE_FREECOM is not set # CONFIG_USB_STORAGE_FREECOM is not set
# CONFIG_USB_STORAGE_ISD200 is not set # CONFIG_USB_STORAGE_ISD200 is not set
# CONFIG_USB_STORAGE_DPCM is not set
# CONFIG_USB_STORAGE_USBAT is not set # CONFIG_USB_STORAGE_USBAT is not set
# CONFIG_USB_STORAGE_SDDR09 is not set # CONFIG_USB_STORAGE_SDDR09 is not set
# CONFIG_USB_STORAGE_SDDR55 is not set # CONFIG_USB_STORAGE_SDDR55 is not set
...@@ -950,7 +1030,6 @@ CONFIG_USB_STORAGE=m ...@@ -950,7 +1030,6 @@ CONFIG_USB_STORAGE=m
# CONFIG_USB_STORAGE_ALAUDA is not set # CONFIG_USB_STORAGE_ALAUDA is not set
# CONFIG_USB_STORAGE_ONETOUCH is not set # CONFIG_USB_STORAGE_ONETOUCH is not set
# CONFIG_USB_STORAGE_KARMA is not set # CONFIG_USB_STORAGE_KARMA is not set
# CONFIG_USB_STORAGE_SIERRA is not set
# CONFIG_USB_STORAGE_CYPRESS_ATACB is not set # CONFIG_USB_STORAGE_CYPRESS_ATACB is not set
# CONFIG_USB_LIBUSUAL is not set # CONFIG_USB_LIBUSUAL is not set
...@@ -971,6 +1050,7 @@ CONFIG_USB_STORAGE=m ...@@ -971,6 +1050,7 @@ CONFIG_USB_STORAGE=m
# CONFIG_USB_EMI62 is not set # CONFIG_USB_EMI62 is not set
# CONFIG_USB_EMI26 is not set # CONFIG_USB_EMI26 is not set
# CONFIG_USB_ADUTUX is not set # CONFIG_USB_ADUTUX is not set
# CONFIG_USB_SEVSEG is not set
# CONFIG_USB_RIO500 is not set # CONFIG_USB_RIO500 is not set
# CONFIG_USB_LEGOTOWER is not set # CONFIG_USB_LEGOTOWER is not set
# CONFIG_USB_LCD is not set # CONFIG_USB_LCD is not set
...@@ -988,7 +1068,12 @@ CONFIG_USB_STORAGE=m ...@@ -988,7 +1068,12 @@ CONFIG_USB_STORAGE=m
# CONFIG_USB_IOWARRIOR is not set # CONFIG_USB_IOWARRIOR is not set
# CONFIG_USB_TEST is not set # CONFIG_USB_TEST is not set
# CONFIG_USB_ISIGHTFW is not set # CONFIG_USB_ISIGHTFW is not set
# CONFIG_USB_VST is not set
# CONFIG_USB_GADGET is not set # CONFIG_USB_GADGET is not set
#
# OTG and related infrastructure
#
# CONFIG_MMC is not set # CONFIG_MMC is not set
# CONFIG_MEMSTICK is not set # CONFIG_MEMSTICK is not set
# CONFIG_NEW_LEDS is not set # CONFIG_NEW_LEDS is not set
...@@ -1014,12 +1099,15 @@ CONFIG_RTC_INTF_DEV=y ...@@ -1014,12 +1099,15 @@ CONFIG_RTC_INTF_DEV=y
# Platform RTC drivers # Platform RTC drivers
# #
# CONFIG_RTC_DRV_CMOS is not set # CONFIG_RTC_DRV_CMOS is not set
# CONFIG_RTC_DRV_DS1286 is not set
# CONFIG_RTC_DRV_DS1511 is not set # CONFIG_RTC_DRV_DS1511 is not set
# CONFIG_RTC_DRV_DS1553 is not set # CONFIG_RTC_DRV_DS1553 is not set
# CONFIG_RTC_DRV_DS1742 is not set # CONFIG_RTC_DRV_DS1742 is not set
# CONFIG_RTC_DRV_STK17TA8 is not set # CONFIG_RTC_DRV_STK17TA8 is not set
# CONFIG_RTC_DRV_M48T86 is not set # CONFIG_RTC_DRV_M48T86 is not set
# CONFIG_RTC_DRV_M48T35 is not set
# CONFIG_RTC_DRV_M48T59 is not set # CONFIG_RTC_DRV_M48T59 is not set
# CONFIG_RTC_DRV_BQ4802 is not set
# CONFIG_RTC_DRV_V3020 is not set # CONFIG_RTC_DRV_V3020 is not set
# #
...@@ -1028,6 +1116,7 @@ CONFIG_RTC_INTF_DEV=y ...@@ -1028,6 +1116,7 @@ CONFIG_RTC_INTF_DEV=y
CONFIG_RTC_DRV_PPC=m CONFIG_RTC_DRV_PPC=m
# CONFIG_DMADEVICES is not set # CONFIG_DMADEVICES is not set
# CONFIG_UIO is not set # CONFIG_UIO is not set
# CONFIG_STAGING is not set
# #
# File systems # File systems
...@@ -1035,26 +1124,35 @@ CONFIG_RTC_DRV_PPC=m ...@@ -1035,26 +1124,35 @@ CONFIG_RTC_DRV_PPC=m
CONFIG_EXT2_FS=m CONFIG_EXT2_FS=m
# CONFIG_EXT2_FS_XATTR is not set # CONFIG_EXT2_FS_XATTR is not set
# CONFIG_EXT2_FS_XIP is not set # CONFIG_EXT2_FS_XIP is not set
CONFIG_EXT3_FS=y CONFIG_EXT3_FS=m
CONFIG_EXT3_FS_XATTR=y CONFIG_EXT3_FS_XATTR=y
# CONFIG_EXT3_FS_POSIX_ACL is not set # CONFIG_EXT3_FS_POSIX_ACL is not set
# CONFIG_EXT3_FS_SECURITY is not set # CONFIG_EXT3_FS_SECURITY is not set
# CONFIG_EXT4DEV_FS is not set CONFIG_EXT4_FS=y
CONFIG_JBD=y # CONFIG_EXT4DEV_COMPAT is not set
CONFIG_EXT4_FS_XATTR=y
# CONFIG_EXT4_FS_POSIX_ACL is not set
# CONFIG_EXT4_FS_SECURITY is not set
CONFIG_JBD=m
# CONFIG_JBD_DEBUG is not set # CONFIG_JBD_DEBUG is not set
CONFIG_JBD2=y
# CONFIG_JBD2_DEBUG is not set
CONFIG_FS_MBCACHE=y CONFIG_FS_MBCACHE=y
# CONFIG_REISERFS_FS is not set # CONFIG_REISERFS_FS is not set
# CONFIG_JFS_FS is not set # CONFIG_JFS_FS is not set
# CONFIG_FS_POSIX_ACL is not set # CONFIG_FS_POSIX_ACL is not set
CONFIG_FILE_LOCKING=y
# CONFIG_XFS_FS is not set # CONFIG_XFS_FS is not set
# CONFIG_GFS2_FS is not set # CONFIG_GFS2_FS is not set
# CONFIG_OCFS2_FS is not set # CONFIG_OCFS2_FS is not set
# CONFIG_BTRFS_FS is not set
CONFIG_DNOTIFY=y CONFIG_DNOTIFY=y
CONFIG_INOTIFY=y CONFIG_INOTIFY=y
CONFIG_INOTIFY_USER=y CONFIG_INOTIFY_USER=y
CONFIG_QUOTA=y CONFIG_QUOTA=y
# CONFIG_QUOTA_NETLINK_INTERFACE is not set # CONFIG_QUOTA_NETLINK_INTERFACE is not set
CONFIG_PRINT_QUOTA_WARNING=y CONFIG_PRINT_QUOTA_WARNING=y
CONFIG_QUOTA_TREE=y
# CONFIG_QFMT_V1 is not set # CONFIG_QFMT_V1 is not set
CONFIG_QFMT_V2=y CONFIG_QFMT_V2=y
CONFIG_QUOTACTL=y CONFIG_QUOTACTL=y
...@@ -1087,16 +1185,14 @@ CONFIG_FAT_DEFAULT_IOCHARSET="iso8859-1" ...@@ -1087,16 +1185,14 @@ CONFIG_FAT_DEFAULT_IOCHARSET="iso8859-1"
CONFIG_PROC_FS=y CONFIG_PROC_FS=y
CONFIG_PROC_KCORE=y CONFIG_PROC_KCORE=y
CONFIG_PROC_SYSCTL=y CONFIG_PROC_SYSCTL=y
CONFIG_PROC_PAGE_MONITOR=y
CONFIG_SYSFS=y CONFIG_SYSFS=y
CONFIG_TMPFS=y CONFIG_TMPFS=y
# CONFIG_TMPFS_POSIX_ACL is not set # CONFIG_TMPFS_POSIX_ACL is not set
CONFIG_HUGETLBFS=y CONFIG_HUGETLBFS=y
CONFIG_HUGETLB_PAGE=y CONFIG_HUGETLB_PAGE=y
# CONFIG_CONFIGFS_FS is not set # CONFIG_CONFIGFS_FS is not set
CONFIG_MISC_FILESYSTEMS=y
#
# Miscellaneous filesystems
#
# CONFIG_ADFS_FS is not set # CONFIG_ADFS_FS is not set
# CONFIG_AFFS_FS is not set # CONFIG_AFFS_FS is not set
# CONFIG_HFS_FS is not set # CONFIG_HFS_FS is not set
...@@ -1106,6 +1202,7 @@ CONFIG_HUGETLB_PAGE=y ...@@ -1106,6 +1202,7 @@ CONFIG_HUGETLB_PAGE=y
# CONFIG_EFS_FS is not set # CONFIG_EFS_FS is not set
# CONFIG_JFFS2_FS is not set # CONFIG_JFFS2_FS is not set
# CONFIG_CRAMFS is not set # CONFIG_CRAMFS is not set
# CONFIG_SQUASHFS is not set
# CONFIG_VXFS_FS is not set # CONFIG_VXFS_FS is not set
# CONFIG_MINIX_FS is not set # CONFIG_MINIX_FS is not set
# CONFIG_OMFS_FS is not set # CONFIG_OMFS_FS is not set
...@@ -1126,6 +1223,7 @@ CONFIG_LOCKD_V4=y ...@@ -1126,6 +1223,7 @@ CONFIG_LOCKD_V4=y
CONFIG_NFS_COMMON=y CONFIG_NFS_COMMON=y
CONFIG_SUNRPC=y CONFIG_SUNRPC=y
CONFIG_SUNRPC_GSS=y CONFIG_SUNRPC_GSS=y
# CONFIG_SUNRPC_REGISTER_V4 is not set
CONFIG_RPCSEC_GSS_KRB5=y CONFIG_RPCSEC_GSS_KRB5=y
# CONFIG_RPCSEC_GSS_SPKM3 is not set # CONFIG_RPCSEC_GSS_SPKM3 is not set
# CONFIG_SMB_FS is not set # CONFIG_SMB_FS is not set
...@@ -1190,9 +1288,9 @@ CONFIG_NLS_ISO8859_1=y ...@@ -1190,9 +1288,9 @@ CONFIG_NLS_ISO8859_1=y
# Library routines # Library routines
# #
CONFIG_BITREVERSE=y CONFIG_BITREVERSE=y
# CONFIG_GENERIC_FIND_FIRST_BIT is not set CONFIG_GENERIC_FIND_LAST_BIT=y
CONFIG_CRC_CCITT=m CONFIG_CRC_CCITT=m
# CONFIG_CRC16 is not set CONFIG_CRC16=y
CONFIG_CRC_T10DIF=y CONFIG_CRC_T10DIF=y
CONFIG_CRC_ITU_T=m CONFIG_CRC_ITU_T=m
CONFIG_CRC32=y CONFIG_CRC32=y
...@@ -1250,27 +1348,44 @@ CONFIG_DEBUG_WRITECOUNT=y ...@@ -1250,27 +1348,44 @@ CONFIG_DEBUG_WRITECOUNT=y
CONFIG_DEBUG_MEMORY_INIT=y CONFIG_DEBUG_MEMORY_INIT=y
CONFIG_DEBUG_LIST=y CONFIG_DEBUG_LIST=y
# CONFIG_DEBUG_SG is not set # CONFIG_DEBUG_SG is not set
CONFIG_FRAME_POINTER=y # CONFIG_DEBUG_NOTIFIERS is not set
# CONFIG_BOOT_PRINTK_DELAY is not set # CONFIG_BOOT_PRINTK_DELAY is not set
# CONFIG_RCU_TORTURE_TEST is not set # CONFIG_RCU_TORTURE_TEST is not set
# CONFIG_RCU_CPU_STALL_DETECTOR is not set
# CONFIG_BACKTRACE_SELF_TEST is not set # CONFIG_BACKTRACE_SELF_TEST is not set
# CONFIG_DEBUG_BLOCK_EXT_DEVT is not set
# CONFIG_FAULT_INJECTION is not set # CONFIG_FAULT_INJECTION is not set
# CONFIG_LATENCYTOP is not set # CONFIG_LATENCYTOP is not set
CONFIG_SYSCTL_SYSCALL_CHECK=y CONFIG_SYSCTL_SYSCALL_CHECK=y
CONFIG_HAVE_FTRACE=y CONFIG_NOP_TRACER=y
CONFIG_HAVE_FUNCTION_TRACER=y
CONFIG_HAVE_DYNAMIC_FTRACE=y CONFIG_HAVE_DYNAMIC_FTRACE=y
# CONFIG_FTRACE is not set CONFIG_HAVE_FTRACE_MCOUNT_RECORD=y
CONFIG_RING_BUFFER=y
CONFIG_TRACING=y
#
# Tracers
#
# CONFIG_FUNCTION_TRACER is not set
# CONFIG_IRQSOFF_TRACER is not set # CONFIG_IRQSOFF_TRACER is not set
# CONFIG_SCHED_TRACER is not set # CONFIG_SCHED_TRACER is not set
# CONFIG_CONTEXT_SWITCH_TRACER is not set # CONFIG_CONTEXT_SWITCH_TRACER is not set
# CONFIG_BOOT_TRACER is not set
# CONFIG_TRACE_BRANCH_PROFILING is not set
# CONFIG_STACK_TRACER is not set
# CONFIG_FTRACE_STARTUP_TEST is not set
# CONFIG_DYNAMIC_PRINTK_DEBUG is not set
# CONFIG_SAMPLES is not set # CONFIG_SAMPLES is not set
CONFIG_HAVE_ARCH_KGDB=y CONFIG_HAVE_ARCH_KGDB=y
# CONFIG_KGDB is not set # CONFIG_KGDB is not set
CONFIG_PRINT_STACK_DEPTH=64
CONFIG_DEBUG_STACKOVERFLOW=y CONFIG_DEBUG_STACKOVERFLOW=y
# CONFIG_DEBUG_STACK_USAGE is not set # CONFIG_DEBUG_STACK_USAGE is not set
# CONFIG_DEBUG_PAGEALLOC is not set # CONFIG_DEBUG_PAGEALLOC is not set
# CONFIG_CODE_PATCHING_SELFTEST is not set # CONFIG_CODE_PATCHING_SELFTEST is not set
# CONFIG_FTR_FIXUP_SELFTEST is not set # CONFIG_FTR_FIXUP_SELFTEST is not set
# CONFIG_MSI_BITMAP_SELFTEST is not set
# CONFIG_XMON is not set # CONFIG_XMON is not set
CONFIG_IRQSTACKS=y CONFIG_IRQSTACKS=y
# CONFIG_VIRQ_DEBUG is not set # CONFIG_VIRQ_DEBUG is not set
...@@ -1282,16 +1397,26 @@ CONFIG_IRQSTACKS=y ...@@ -1282,16 +1397,26 @@ CONFIG_IRQSTACKS=y
# #
# CONFIG_KEYS is not set # CONFIG_KEYS is not set
# CONFIG_SECURITY is not set # CONFIG_SECURITY is not set
# CONFIG_SECURITYFS is not set
# CONFIG_SECURITY_FILE_CAPABILITIES is not set # CONFIG_SECURITY_FILE_CAPABILITIES is not set
CONFIG_CRYPTO=y CONFIG_CRYPTO=y
# #
# Crypto core or helper # Crypto core or helper
# #
# CONFIG_CRYPTO_FIPS is not set
CONFIG_CRYPTO_ALGAPI=y CONFIG_CRYPTO_ALGAPI=y
CONFIG_CRYPTO_ALGAPI2=y
CONFIG_CRYPTO_AEAD=m CONFIG_CRYPTO_AEAD=m
CONFIG_CRYPTO_AEAD2=y
CONFIG_CRYPTO_BLKCIPHER=y CONFIG_CRYPTO_BLKCIPHER=y
CONFIG_CRYPTO_BLKCIPHER2=y
CONFIG_CRYPTO_HASH=y
CONFIG_CRYPTO_HASH2=y
CONFIG_CRYPTO_RNG=m
CONFIG_CRYPTO_RNG2=y
CONFIG_CRYPTO_MANAGER=y CONFIG_CRYPTO_MANAGER=y
CONFIG_CRYPTO_MANAGER2=y
CONFIG_CRYPTO_GF128MUL=m CONFIG_CRYPTO_GF128MUL=m
# CONFIG_CRYPTO_NULL is not set # CONFIG_CRYPTO_NULL is not set
# CONFIG_CRYPTO_CRYPTD is not set # CONFIG_CRYPTO_CRYPTD is not set
...@@ -1363,6 +1488,11 @@ CONFIG_CRYPTO_SALSA20=m ...@@ -1363,6 +1488,11 @@ CONFIG_CRYPTO_SALSA20=m
# #
# CONFIG_CRYPTO_DEFLATE is not set # CONFIG_CRYPTO_DEFLATE is not set
CONFIG_CRYPTO_LZO=m CONFIG_CRYPTO_LZO=m
#
# Random Number Generation
#
# CONFIG_CRYPTO_ANSI_CPRNG is not set
CONFIG_CRYPTO_HW=y CONFIG_CRYPTO_HW=y
# CONFIG_PPC_CLOCK is not set # CONFIG_PPC_CLOCK is not set
# CONFIG_VIRTUALIZATION is not set # CONFIG_VIRTUALIZATION is not set
...@@ -241,9 +241,11 @@ extern const char *powerpc_base_platform; ...@@ -241,9 +241,11 @@ extern const char *powerpc_base_platform;
/* We need to mark all pages as being coherent if we're SMP or we have a /* We need to mark all pages as being coherent if we're SMP or we have a
* 74[45]x and an MPC107 host bridge. Also 83xx and PowerQUICC II * 74[45]x and an MPC107 host bridge. Also 83xx and PowerQUICC II
* require it for PCI "streaming/prefetch" to work properly. * require it for PCI "streaming/prefetch" to work properly.
* This is also required by 52xx family.
*/ */
#if defined(CONFIG_SMP) || defined(CONFIG_MPC10X_BRIDGE) \ #if defined(CONFIG_SMP) || defined(CONFIG_MPC10X_BRIDGE) \
|| defined(CONFIG_PPC_83xx) || defined(CONFIG_8260) || defined(CONFIG_PPC_83xx) || defined(CONFIG_8260) \
|| defined(CONFIG_PPC_MPC52xx)
#define CPU_FTR_COMMON CPU_FTR_NEED_COHERENT #define CPU_FTR_COMMON CPU_FTR_NEED_COHERENT
#else #else
#define CPU_FTR_COMMON 0 #define CPU_FTR_COMMON 0
......
...@@ -511,7 +511,7 @@ InstructionTLBMiss: ...@@ -511,7 +511,7 @@ InstructionTLBMiss:
and r1,r1,r2 /* writable if _RW and _DIRTY */ and r1,r1,r2 /* writable if _RW and _DIRTY */
rlwimi r3,r3,32-1,30,30 /* _PAGE_USER -> PP msb */ rlwimi r3,r3,32-1,30,30 /* _PAGE_USER -> PP msb */
rlwimi r3,r3,32-1,31,31 /* _PAGE_USER -> PP lsb */ rlwimi r3,r3,32-1,31,31 /* _PAGE_USER -> PP lsb */
ori r1,r1,0xe14 /* clear out reserved bits and M */ ori r1,r1,0xe04 /* clear out reserved bits */
andc r1,r3,r1 /* PP = user? (rw&dirty? 2: 3): 0 */ andc r1,r3,r1 /* PP = user? (rw&dirty? 2: 3): 0 */
mtspr SPRN_RPA,r1 mtspr SPRN_RPA,r1
mfspr r3,SPRN_IMISS mfspr r3,SPRN_IMISS
...@@ -585,7 +585,7 @@ DataLoadTLBMiss: ...@@ -585,7 +585,7 @@ DataLoadTLBMiss:
and r1,r1,r2 /* writable if _RW and _DIRTY */ and r1,r1,r2 /* writable if _RW and _DIRTY */
rlwimi r3,r3,32-1,30,30 /* _PAGE_USER -> PP msb */ rlwimi r3,r3,32-1,30,30 /* _PAGE_USER -> PP msb */
rlwimi r3,r3,32-1,31,31 /* _PAGE_USER -> PP lsb */ rlwimi r3,r3,32-1,31,31 /* _PAGE_USER -> PP lsb */
ori r1,r1,0xe14 /* clear out reserved bits and M */ ori r1,r1,0xe04 /* clear out reserved bits */
andc r1,r3,r1 /* PP = user? (rw&dirty? 2: 3): 0 */ andc r1,r3,r1 /* PP = user? (rw&dirty? 2: 3): 0 */
mtspr SPRN_RPA,r1 mtspr SPRN_RPA,r1
mfspr r3,SPRN_DMISS mfspr r3,SPRN_DMISS
...@@ -653,7 +653,7 @@ DataStoreTLBMiss: ...@@ -653,7 +653,7 @@ DataStoreTLBMiss:
stw r3,0(r2) /* update PTE (accessed/dirty bits) */ stw r3,0(r2) /* update PTE (accessed/dirty bits) */
/* Convert linux-style PTE to low word of PPC-style PTE */ /* Convert linux-style PTE to low word of PPC-style PTE */
rlwimi r3,r3,32-1,30,30 /* _PAGE_USER -> PP msb */ rlwimi r3,r3,32-1,30,30 /* _PAGE_USER -> PP msb */
li r1,0xe15 /* clear out reserved bits and M */ li r1,0xe05 /* clear out reserved bits & PP lsb */
andc r1,r3,r1 /* PP = user? 2: 0 */ andc r1,r3,r1 /* PP = user? 2: 0 */
mtspr SPRN_RPA,r1 mtspr SPRN_RPA,r1
mfspr r3,SPRN_DMISS mfspr r3,SPRN_DMISS
......
...@@ -128,6 +128,13 @@ config PS3_FLASH ...@@ -128,6 +128,13 @@ config PS3_FLASH
be disabled on the kernel command line using "ps3flash=off", to be disabled on the kernel command line using "ps3flash=off", to
not allocate this fixed buffer. not allocate this fixed buffer.
config PS3_VRAM
tristate "PS3 Video RAM Storage Driver"
depends on FB_PS3=y && BLOCK && m
help
This driver allows you to use excess PS3 video RAM as volatile
storage or system swap.
config PS3_LPM config PS3_LPM
tristate "PS3 Logical Performance Monitor support" tristate "PS3 Logical Performance Monitor support"
depends on PPC_PS3 depends on PPC_PS3
......
...@@ -9,6 +9,7 @@ obj-$(CONFIG_MAC_FLOPPY) += swim3.o ...@@ -9,6 +9,7 @@ obj-$(CONFIG_MAC_FLOPPY) += swim3.o
obj-$(CONFIG_BLK_DEV_FD) += floppy.o obj-$(CONFIG_BLK_DEV_FD) += floppy.o
obj-$(CONFIG_AMIGA_FLOPPY) += amiflop.o obj-$(CONFIG_AMIGA_FLOPPY) += amiflop.o
obj-$(CONFIG_PS3_DISK) += ps3disk.o obj-$(CONFIG_PS3_DISK) += ps3disk.o
obj-$(CONFIG_PS3_VRAM) += ps3vram.o
obj-$(CONFIG_ATARI_FLOPPY) += ataflop.o obj-$(CONFIG_ATARI_FLOPPY) += ataflop.o
obj-$(CONFIG_AMIGA_Z2RAM) += z2ram.o obj-$(CONFIG_AMIGA_Z2RAM) += z2ram.o
obj-$(CONFIG_BLK_DEV_RAM) += brd.o obj-$(CONFIG_BLK_DEV_RAM) += brd.o
......
/** /*
* ps3vram - Use extra PS3 video ram as MTD block device. * ps3vram - Use extra PS3 video ram as MTD block device.
* *
* Copyright 2009 Sony Corporation
*
* Based on the MTD ps3vram driver, which is
* Copyright (c) 2007-2008 Jim Paris <jim@jtan.com> * Copyright (c) 2007-2008 Jim Paris <jim@jtan.com>
* Added support RSX DMA Vivien Chappelier <vivien.chappelier@free.fr> * Added support RSX DMA Vivien Chappelier <vivien.chappelier@free.fr>
*/ */
#include <linux/io.h> #include <linux/blkdev.h>
#include <linux/mm.h>
#include <linux/init.h>
#include <linux/kernel.h>
#include <linux/list.h>
#include <linux/module.h>
#include <linux/moduleparam.h>
#include <linux/slab.h>
#include <linux/version.h>
#include <linux/gfp.h>
#include <linux/delay.h> #include <linux/delay.h>
#include <linux/mtd/mtd.h> #include <linux/proc_fs.h>
#include <linux/seq_file.h>
#include <asm/firmware.h>
#include <asm/lv1call.h> #include <asm/lv1call.h>
#include <asm/ps3.h> #include <asm/ps3.h>
#define DEVICE_NAME "ps3vram" #define DEVICE_NAME "ps3vram"
#define XDR_BUF_SIZE (2 * 1024 * 1024) /* XDR buffer (must be 1MiB aligned) */ #define XDR_BUF_SIZE (2 * 1024 * 1024) /* XDR buffer (must be 1MiB aligned) */
#define XDR_IOIF 0x0c000000 #define XDR_IOIF 0x0c000000
...@@ -49,8 +47,6 @@ ...@@ -49,8 +47,6 @@
#define L1GPU_CONTEXT_ATTRIBUTE_FB_BLIT 0x601 #define L1GPU_CONTEXT_ATTRIBUTE_FB_BLIT 0x601
struct mtd_info ps3vram_mtd;
#define CACHE_PAGE_PRESENT 1 #define CACHE_PAGE_PRESENT 1
#define CACHE_PAGE_DIRTY 2 #define CACHE_PAGE_DIRTY 2
...@@ -63,9 +59,16 @@ struct ps3vram_cache { ...@@ -63,9 +59,16 @@ struct ps3vram_cache {
unsigned int page_count; unsigned int page_count;
unsigned int page_size; unsigned int page_size;
struct ps3vram_tag *tags; struct ps3vram_tag *tags;
unsigned int hit;
unsigned int miss;
}; };
struct ps3vram_priv { struct ps3vram_priv {
struct request_queue *queue;
struct gendisk *gendisk;
u64 size;
u64 memory_handle; u64 memory_handle;
u64 context_handle; u64 context_handle;
u32 *ctrl; u32 *ctrl;
...@@ -76,43 +79,50 @@ struct ps3vram_priv { ...@@ -76,43 +79,50 @@ struct ps3vram_priv {
u32 *fifo_base; u32 *fifo_base;
u32 *fifo_ptr; u32 *fifo_ptr;
struct device *dev;
struct ps3vram_cache cache; struct ps3vram_cache cache;
/* Used to serialize cache/DMA operations */ /* Used to serialize cache/DMA operations */
struct mutex lock; struct mutex lock;
}; };
static int ps3vram_major;
static struct block_device_operations ps3vram_fops = {
.owner = THIS_MODULE,
};
#define DMA_NOTIFIER_HANDLE_BASE 0x66604200 /* first DMA notifier handle */ #define DMA_NOTIFIER_HANDLE_BASE 0x66604200 /* first DMA notifier handle */
#define DMA_NOTIFIER_OFFSET_BASE 0x1000 /* first DMA notifier offset */ #define DMA_NOTIFIER_OFFSET_BASE 0x1000 /* first DMA notifier offset */
#define DMA_NOTIFIER_SIZE 0x40 #define DMA_NOTIFIER_SIZE 0x40
#define NOTIFIER 7 /* notifier used for completion report */ #define NOTIFIER 7 /* notifier used for completion report */
/* A trailing '-' means to subtract off ps3fb_videomemory.size */ static char *size = "256M";
char *size = "256M-";
module_param(size, charp, 0); module_param(size, charp, 0);
MODULE_PARM_DESC(size, "memory size"); MODULE_PARM_DESC(size, "memory size");
static u32 *ps3vram_get_notifier(u32 *reports, int notifier) static u32 *ps3vram_get_notifier(u32 *reports, int notifier)
{ {
return (void *) reports + return (void *)reports + DMA_NOTIFIER_OFFSET_BASE +
DMA_NOTIFIER_OFFSET_BASE +
DMA_NOTIFIER_SIZE * notifier; DMA_NOTIFIER_SIZE * notifier;
} }
static void ps3vram_notifier_reset(struct mtd_info *mtd) static void ps3vram_notifier_reset(struct ps3_system_bus_device *dev)
{ {
struct ps3vram_priv *priv = dev->core.driver_data;
u32 *notify = ps3vram_get_notifier(priv->reports, NOTIFIER);
int i; int i;
struct ps3vram_priv *priv = mtd->priv;
u32 *notify = ps3vram_get_notifier(priv->reports, NOTIFIER);
for (i = 0; i < 4; i++) for (i = 0; i < 4; i++)
notify[i] = 0xffffffff; notify[i] = 0xffffffff;
} }
static int ps3vram_notifier_wait(struct mtd_info *mtd, unsigned int timeout_ms) static int ps3vram_notifier_wait(struct ps3_system_bus_device *dev,
unsigned int timeout_ms)
{ {
struct ps3vram_priv *priv = mtd->priv; struct ps3vram_priv *priv = dev->core.driver_data;
u32 *notify = ps3vram_get_notifier(priv->reports, NOTIFIER); u32 *notify = ps3vram_get_notifier(priv->reports, NOTIFIER);
unsigned long timeout = jiffies + msecs_to_jiffies(timeout_ms); unsigned long timeout = jiffies + msecs_to_jiffies(timeout_ms);
...@@ -125,17 +135,18 @@ static int ps3vram_notifier_wait(struct mtd_info *mtd, unsigned int timeout_ms) ...@@ -125,17 +135,18 @@ static int ps3vram_notifier_wait(struct mtd_info *mtd, unsigned int timeout_ms)
return -ETIMEDOUT; return -ETIMEDOUT;
} }
static void ps3vram_init_ring(struct mtd_info *mtd) static void ps3vram_init_ring(struct ps3_system_bus_device *dev)
{ {
struct ps3vram_priv *priv = mtd->priv; struct ps3vram_priv *priv = dev->core.driver_data;
priv->ctrl[CTRL_PUT] = FIFO_BASE + FIFO_OFFSET; priv->ctrl[CTRL_PUT] = FIFO_BASE + FIFO_OFFSET;
priv->ctrl[CTRL_GET] = FIFO_BASE + FIFO_OFFSET; priv->ctrl[CTRL_GET] = FIFO_BASE + FIFO_OFFSET;
} }
static int ps3vram_wait_ring(struct mtd_info *mtd, unsigned int timeout_ms) static int ps3vram_wait_ring(struct ps3_system_bus_device *dev,
unsigned int timeout_ms)
{ {
struct ps3vram_priv *priv = mtd->priv; struct ps3vram_priv *priv = dev->core.driver_data;
unsigned long timeout = jiffies + msecs_to_jiffies(timeout_ms); unsigned long timeout = jiffies + msecs_to_jiffies(timeout_ms);
do { do {
...@@ -144,8 +155,8 @@ static int ps3vram_wait_ring(struct mtd_info *mtd, unsigned int timeout_ms) ...@@ -144,8 +155,8 @@ static int ps3vram_wait_ring(struct mtd_info *mtd, unsigned int timeout_ms)
msleep(1); msleep(1);
} while (time_before(jiffies, timeout)); } while (time_before(jiffies, timeout));
dev_dbg(priv->dev, "%s:%d: FIFO timeout (%08x/%08x/%08x)\n", __func__, dev_warn(&dev->core, "FIFO timeout (%08x/%08x/%08x)\n",
__LINE__, priv->ctrl[CTRL_PUT], priv->ctrl[CTRL_GET], priv->ctrl[CTRL_PUT], priv->ctrl[CTRL_GET],
priv->ctrl[CTRL_TOP]); priv->ctrl[CTRL_TOP]);
return -ETIMEDOUT; return -ETIMEDOUT;
...@@ -156,64 +167,65 @@ static void ps3vram_out_ring(struct ps3vram_priv *priv, u32 data) ...@@ -156,64 +167,65 @@ static void ps3vram_out_ring(struct ps3vram_priv *priv, u32 data)
*(priv->fifo_ptr)++ = data; *(priv->fifo_ptr)++ = data;
} }
static void ps3vram_begin_ring(struct ps3vram_priv *priv, u32 chan, static void ps3vram_begin_ring(struct ps3vram_priv *priv, u32 chan, u32 tag,
u32 tag, u32 size) u32 size)
{ {
ps3vram_out_ring(priv, (size << 18) | (chan << 13) | tag); ps3vram_out_ring(priv, (size << 18) | (chan << 13) | tag);
} }
static void ps3vram_rewind_ring(struct mtd_info *mtd) static void ps3vram_rewind_ring(struct ps3_system_bus_device *dev)
{ {
struct ps3vram_priv *priv = mtd->priv; struct ps3vram_priv *priv = dev->core.driver_data;
u64 status; int status;
ps3vram_out_ring(priv, 0x20000000 | (FIFO_BASE + FIFO_OFFSET)); ps3vram_out_ring(priv, 0x20000000 | (FIFO_BASE + FIFO_OFFSET));
priv->ctrl[CTRL_PUT] = FIFO_BASE + FIFO_OFFSET; priv->ctrl[CTRL_PUT] = FIFO_BASE + FIFO_OFFSET;
/* asking the HV for a blit will kick the fifo */ /* asking the HV for a blit will kick the FIFO */
status = lv1_gpu_context_attribute(priv->context_handle, status = lv1_gpu_context_attribute(priv->context_handle,
L1GPU_CONTEXT_ATTRIBUTE_FB_BLIT, L1GPU_CONTEXT_ATTRIBUTE_FB_BLIT, 0,
0, 0, 0, 0); 0, 0, 0);
if (status) if (status)
dev_err(priv->dev, "%s:%d: lv1_gpu_context_attribute failed\n", dev_err(&dev->core,
__func__, __LINE__); "%s: lv1_gpu_context_attribute failed %d\n", __func__,
status);
priv->fifo_ptr = priv->fifo_base; priv->fifo_ptr = priv->fifo_base;
} }
static void ps3vram_fire_ring(struct mtd_info *mtd) static void ps3vram_fire_ring(struct ps3_system_bus_device *dev)
{ {
struct ps3vram_priv *priv = mtd->priv; struct ps3vram_priv *priv = dev->core.driver_data;
u64 status; int status;
mutex_lock(&ps3_gpu_mutex); mutex_lock(&ps3_gpu_mutex);
priv->ctrl[CTRL_PUT] = FIFO_BASE + FIFO_OFFSET + priv->ctrl[CTRL_PUT] = FIFO_BASE + FIFO_OFFSET +
(priv->fifo_ptr - priv->fifo_base) * sizeof(u32); (priv->fifo_ptr - priv->fifo_base) * sizeof(u32);
/* asking the HV for a blit will kick the fifo */ /* asking the HV for a blit will kick the FIFO */
status = lv1_gpu_context_attribute(priv->context_handle, status = lv1_gpu_context_attribute(priv->context_handle,
L1GPU_CONTEXT_ATTRIBUTE_FB_BLIT, L1GPU_CONTEXT_ATTRIBUTE_FB_BLIT, 0,
0, 0, 0, 0); 0, 0, 0);
if (status) if (status)
dev_err(priv->dev, "%s:%d: lv1_gpu_context_attribute failed\n", dev_err(&dev->core,
__func__, __LINE__); "%s: lv1_gpu_context_attribute failed %d\n", __func__,
status);
if ((priv->fifo_ptr - priv->fifo_base) * sizeof(u32) > if ((priv->fifo_ptr - priv->fifo_base) * sizeof(u32) >
FIFO_SIZE - 1024) { FIFO_SIZE - 1024) {
dev_dbg(priv->dev, "%s:%d: fifo full, rewinding\n", __func__, dev_dbg(&dev->core, "FIFO full, rewinding\n");
__LINE__); ps3vram_wait_ring(dev, 200);
ps3vram_wait_ring(mtd, 200); ps3vram_rewind_ring(dev);
ps3vram_rewind_ring(mtd);
} }
mutex_unlock(&ps3_gpu_mutex); mutex_unlock(&ps3_gpu_mutex);
} }
static void ps3vram_bind(struct mtd_info *mtd) static void ps3vram_bind(struct ps3_system_bus_device *dev)
{ {
struct ps3vram_priv *priv = mtd->priv; struct ps3vram_priv *priv = dev->core.driver_data;
ps3vram_begin_ring(priv, UPLOAD_SUBCH, 0, 1); ps3vram_begin_ring(priv, UPLOAD_SUBCH, 0, 1);
ps3vram_out_ring(priv, 0x31337303); ps3vram_out_ring(priv, 0x31337303);
...@@ -229,13 +241,14 @@ static void ps3vram_bind(struct mtd_info *mtd) ...@@ -229,13 +241,14 @@ static void ps3vram_bind(struct mtd_info *mtd)
ps3vram_out_ring(priv, 0xfeed0000); /* DMA video RAM instance */ ps3vram_out_ring(priv, 0xfeed0000); /* DMA video RAM instance */
ps3vram_out_ring(priv, 0xfeed0001); /* DMA system RAM instance */ ps3vram_out_ring(priv, 0xfeed0001); /* DMA system RAM instance */
ps3vram_fire_ring(mtd); ps3vram_fire_ring(dev);
} }
static int ps3vram_upload(struct mtd_info *mtd, unsigned int src_offset, static int ps3vram_upload(struct ps3_system_bus_device *dev,
unsigned int dst_offset, int len, int count) unsigned int src_offset, unsigned int dst_offset,
int len, int count)
{ {
struct ps3vram_priv *priv = mtd->priv; struct ps3vram_priv *priv = dev->core.driver_data;
ps3vram_begin_ring(priv, UPLOAD_SUBCH, ps3vram_begin_ring(priv, UPLOAD_SUBCH,
NV_MEMORY_TO_MEMORY_FORMAT_OFFSET_IN, 8); NV_MEMORY_TO_MEMORY_FORMAT_OFFSET_IN, 8);
...@@ -248,26 +261,26 @@ static int ps3vram_upload(struct mtd_info *mtd, unsigned int src_offset, ...@@ -248,26 +261,26 @@ static int ps3vram_upload(struct mtd_info *mtd, unsigned int src_offset,
ps3vram_out_ring(priv, (1 << 8) | 1); ps3vram_out_ring(priv, (1 << 8) | 1);
ps3vram_out_ring(priv, 0); ps3vram_out_ring(priv, 0);
ps3vram_notifier_reset(mtd); ps3vram_notifier_reset(dev);
ps3vram_begin_ring(priv, UPLOAD_SUBCH, ps3vram_begin_ring(priv, UPLOAD_SUBCH,
NV_MEMORY_TO_MEMORY_FORMAT_NOTIFY, 1); NV_MEMORY_TO_MEMORY_FORMAT_NOTIFY, 1);
ps3vram_out_ring(priv, 0); ps3vram_out_ring(priv, 0);
ps3vram_begin_ring(priv, UPLOAD_SUBCH, 0x100, 1); ps3vram_begin_ring(priv, UPLOAD_SUBCH, 0x100, 1);
ps3vram_out_ring(priv, 0); ps3vram_out_ring(priv, 0);
ps3vram_fire_ring(mtd); ps3vram_fire_ring(dev);
if (ps3vram_notifier_wait(mtd, 200) < 0) { if (ps3vram_notifier_wait(dev, 200) < 0) {
dev_dbg(priv->dev, "%s:%d: notifier timeout\n", __func__, dev_warn(&dev->core, "%s: Notifier timeout\n", __func__);
__LINE__);
return -1; return -1;
} }
return 0; return 0;
} }
static int ps3vram_download(struct mtd_info *mtd, unsigned int src_offset, static int ps3vram_download(struct ps3_system_bus_device *dev,
unsigned int dst_offset, int len, int count) unsigned int src_offset, unsigned int dst_offset,
int len, int count)
{ {
struct ps3vram_priv *priv = mtd->priv; struct ps3vram_priv *priv = dev->core.driver_data;
ps3vram_begin_ring(priv, DOWNLOAD_SUBCH, ps3vram_begin_ring(priv, DOWNLOAD_SUBCH,
NV_MEMORY_TO_MEMORY_FORMAT_OFFSET_IN, 8); NV_MEMORY_TO_MEMORY_FORMAT_OFFSET_IN, 8);
...@@ -280,60 +293,56 @@ static int ps3vram_download(struct mtd_info *mtd, unsigned int src_offset, ...@@ -280,60 +293,56 @@ static int ps3vram_download(struct mtd_info *mtd, unsigned int src_offset,
ps3vram_out_ring(priv, (1 << 8) | 1); ps3vram_out_ring(priv, (1 << 8) | 1);
ps3vram_out_ring(priv, 0); ps3vram_out_ring(priv, 0);
ps3vram_notifier_reset(mtd); ps3vram_notifier_reset(dev);
ps3vram_begin_ring(priv, DOWNLOAD_SUBCH, ps3vram_begin_ring(priv, DOWNLOAD_SUBCH,
NV_MEMORY_TO_MEMORY_FORMAT_NOTIFY, 1); NV_MEMORY_TO_MEMORY_FORMAT_NOTIFY, 1);
ps3vram_out_ring(priv, 0); ps3vram_out_ring(priv, 0);
ps3vram_begin_ring(priv, DOWNLOAD_SUBCH, 0x100, 1); ps3vram_begin_ring(priv, DOWNLOAD_SUBCH, 0x100, 1);
ps3vram_out_ring(priv, 0); ps3vram_out_ring(priv, 0);
ps3vram_fire_ring(mtd); ps3vram_fire_ring(dev);
if (ps3vram_notifier_wait(mtd, 200) < 0) { if (ps3vram_notifier_wait(dev, 200) < 0) {
dev_dbg(priv->dev, "%s:%d: notifier timeout\n", __func__, dev_warn(&dev->core, "%s: Notifier timeout\n", __func__);
__LINE__);
return -1; return -1;
} }
return 0; return 0;
} }
static void ps3vram_cache_evict(struct mtd_info *mtd, int entry) static void ps3vram_cache_evict(struct ps3_system_bus_device *dev, int entry)
{ {
struct ps3vram_priv *priv = mtd->priv; struct ps3vram_priv *priv = dev->core.driver_data;
struct ps3vram_cache *cache = &priv->cache; struct ps3vram_cache *cache = &priv->cache;
if (cache->tags[entry].flags & CACHE_PAGE_DIRTY) { if (!(cache->tags[entry].flags & CACHE_PAGE_DIRTY))
dev_dbg(priv->dev, "%s:%d: flushing %d : 0x%08x\n", __func__, return;
__LINE__, entry, cache->tags[entry].address);
if (ps3vram_upload(mtd, dev_dbg(&dev->core, "Flushing %d: 0x%08x\n", entry,
CACHE_OFFSET + entry * cache->page_size, cache->tags[entry].address);
cache->tags[entry].address, if (ps3vram_upload(dev, CACHE_OFFSET + entry * cache->page_size,
DMA_PAGE_SIZE, cache->tags[entry].address, DMA_PAGE_SIZE,
cache->page_size / DMA_PAGE_SIZE) < 0) { cache->page_size / DMA_PAGE_SIZE) < 0) {
dev_dbg(priv->dev, "%s:%d: failed to upload from " dev_err(&dev->core,
"0x%x to 0x%x size 0x%x\n", __func__, __LINE__, "Failed to upload from 0x%x to " "0x%x size 0x%x\n",
entry * cache->page_size, entry * cache->page_size, cache->tags[entry].address,
cache->tags[entry].address, cache->page_size); cache->page_size);
} }
cache->tags[entry].flags &= ~CACHE_PAGE_DIRTY; cache->tags[entry].flags &= ~CACHE_PAGE_DIRTY;
}
} }
static void ps3vram_cache_load(struct mtd_info *mtd, int entry, static void ps3vram_cache_load(struct ps3_system_bus_device *dev, int entry,
unsigned int address) unsigned int address)
{ {
struct ps3vram_priv *priv = mtd->priv; struct ps3vram_priv *priv = dev->core.driver_data;
struct ps3vram_cache *cache = &priv->cache; struct ps3vram_cache *cache = &priv->cache;
dev_dbg(priv->dev, "%s:%d: fetching %d : 0x%08x\n", __func__, __LINE__, dev_dbg(&dev->core, "Fetching %d: 0x%08x\n", entry, address);
entry, address); if (ps3vram_download(dev, address,
if (ps3vram_download(mtd,
address,
CACHE_OFFSET + entry * cache->page_size, CACHE_OFFSET + entry * cache->page_size,
DMA_PAGE_SIZE, DMA_PAGE_SIZE,
cache->page_size / DMA_PAGE_SIZE) < 0) { cache->page_size / DMA_PAGE_SIZE) < 0) {
dev_err(priv->dev, "%s:%d: failed to download from " dev_err(&dev->core,
"0x%x to 0x%x size 0x%x\n", __func__, __LINE__, address, "Failed to download from 0x%x to 0x%x size 0x%x\n",
entry * cache->page_size, cache->page_size); address, entry * cache->page_size, cache->page_size);
} }
cache->tags[entry].address = address; cache->tags[entry].address = address;
...@@ -341,22 +350,23 @@ static void ps3vram_cache_load(struct mtd_info *mtd, int entry, ...@@ -341,22 +350,23 @@ static void ps3vram_cache_load(struct mtd_info *mtd, int entry,
} }
static void ps3vram_cache_flush(struct mtd_info *mtd) static void ps3vram_cache_flush(struct ps3_system_bus_device *dev)
{ {
struct ps3vram_priv *priv = mtd->priv; struct ps3vram_priv *priv = dev->core.driver_data;
struct ps3vram_cache *cache = &priv->cache; struct ps3vram_cache *cache = &priv->cache;
int i; int i;
dev_dbg(priv->dev, "%s:%d: FLUSH\n", __func__, __LINE__); dev_dbg(&dev->core, "FLUSH\n");
for (i = 0; i < cache->page_count; i++) { for (i = 0; i < cache->page_count; i++) {
ps3vram_cache_evict(mtd, i); ps3vram_cache_evict(dev, i);
cache->tags[i].flags = 0; cache->tags[i].flags = 0;
} }
} }
static unsigned int ps3vram_cache_match(struct mtd_info *mtd, loff_t address) static unsigned int ps3vram_cache_match(struct ps3_system_bus_device *dev,
loff_t address)
{ {
struct ps3vram_priv *priv = mtd->priv; struct ps3vram_priv *priv = dev->core.driver_data;
struct ps3vram_cache *cache = &priv->cache; struct ps3vram_cache *cache = &priv->cache;
unsigned int base; unsigned int base;
unsigned int offset; unsigned int offset;
...@@ -370,86 +380,65 @@ static unsigned int ps3vram_cache_match(struct mtd_info *mtd, loff_t address) ...@@ -370,86 +380,65 @@ static unsigned int ps3vram_cache_match(struct mtd_info *mtd, loff_t address)
for (i = 0; i < cache->page_count; i++) { for (i = 0; i < cache->page_count; i++) {
if ((cache->tags[i].flags & CACHE_PAGE_PRESENT) && if ((cache->tags[i].flags & CACHE_PAGE_PRESENT) &&
cache->tags[i].address == base) { cache->tags[i].address == base) {
dev_dbg(priv->dev, "%s:%d: found entry %d : 0x%08x\n", cache->hit++;
__func__, __LINE__, i, cache->tags[i].address); dev_dbg(&dev->core, "Found entry %d: 0x%08x\n", i,
cache->tags[i].address);
return i; return i;
} }
} }
/* choose a random entry */ /* choose a random entry */
i = (jiffies + (counter++)) % cache->page_count; i = (jiffies + (counter++)) % cache->page_count;
dev_dbg(priv->dev, "%s:%d: using entry %d\n", __func__, __LINE__, i); dev_dbg(&dev->core, "Using entry %d\n", i);
ps3vram_cache_evict(mtd, i); ps3vram_cache_evict(dev, i);
ps3vram_cache_load(mtd, i, base); ps3vram_cache_load(dev, i, base);
cache->miss++;
return i; return i;
} }
static int ps3vram_cache_init(struct mtd_info *mtd) static int ps3vram_cache_init(struct ps3_system_bus_device *dev)
{ {
struct ps3vram_priv *priv = mtd->priv; struct ps3vram_priv *priv = dev->core.driver_data;
priv->cache.page_count = CACHE_PAGE_COUNT; priv->cache.page_count = CACHE_PAGE_COUNT;
priv->cache.page_size = CACHE_PAGE_SIZE; priv->cache.page_size = CACHE_PAGE_SIZE;
priv->cache.tags = kzalloc(sizeof(struct ps3vram_tag) * priv->cache.tags = kzalloc(sizeof(struct ps3vram_tag) *
CACHE_PAGE_COUNT, GFP_KERNEL); CACHE_PAGE_COUNT, GFP_KERNEL);
if (priv->cache.tags == NULL) { if (priv->cache.tags == NULL) {
dev_err(priv->dev, "%s:%d: could not allocate cache tags\n", dev_err(&dev->core, "Could not allocate cache tags\n");
__func__, __LINE__);
return -ENOMEM; return -ENOMEM;
} }
dev_info(priv->dev, "created ram cache: %d entries, %d KiB each\n", dev_info(&dev->core, "Created ram cache: %d entries, %d KiB each\n",
CACHE_PAGE_COUNT, CACHE_PAGE_SIZE / 1024); CACHE_PAGE_COUNT, CACHE_PAGE_SIZE / 1024);
return 0; return 0;
} }
static void ps3vram_cache_cleanup(struct mtd_info *mtd) static void ps3vram_cache_cleanup(struct ps3_system_bus_device *dev)
{ {
struct ps3vram_priv *priv = mtd->priv; struct ps3vram_priv *priv = dev->core.driver_data;
ps3vram_cache_flush(mtd); ps3vram_cache_flush(dev);
kfree(priv->cache.tags); kfree(priv->cache.tags);
} }
static int ps3vram_erase(struct mtd_info *mtd, struct erase_info *instr) static int ps3vram_read(struct ps3_system_bus_device *dev, loff_t from,
{ size_t len, size_t *retlen, u_char *buf)
struct ps3vram_priv *priv = mtd->priv;
if (instr->addr + instr->len > mtd->size)
return -EINVAL;
mutex_lock(&priv->lock);
ps3vram_cache_flush(mtd);
/* Set bytes to 0xFF */
memset_io(priv->ddr_base + instr->addr, 0xFF, instr->len);
mutex_unlock(&priv->lock);
instr->state = MTD_ERASE_DONE;
mtd_erase_callback(instr);
return 0;
}
static int ps3vram_read(struct mtd_info *mtd, loff_t from, size_t len,
size_t *retlen, u_char *buf)
{ {
struct ps3vram_priv *priv = mtd->priv; struct ps3vram_priv *priv = dev->core.driver_data;
unsigned int cached, count; unsigned int cached, count;
dev_dbg(priv->dev, "%s:%d: from=0x%08x len=0x%zx\n", __func__, __LINE__, dev_dbg(&dev->core, "%s: from=0x%08x len=0x%zx\n", __func__,
(unsigned int)from, len); (unsigned int)from, len);
if (from >= mtd->size) if (from >= priv->size)
return -EINVAL; return -EIO;
if (len > mtd->size - from) if (len > priv->size - from)
len = mtd->size - from; len = priv->size - from;
/* Copy from vram to buf */ /* Copy from vram to buf */
count = len; count = len;
...@@ -462,11 +451,11 @@ static int ps3vram_read(struct mtd_info *mtd, loff_t from, size_t len, ...@@ -462,11 +451,11 @@ static int ps3vram_read(struct mtd_info *mtd, loff_t from, size_t len,
mutex_lock(&priv->lock); mutex_lock(&priv->lock);
entry = ps3vram_cache_match(mtd, from); entry = ps3vram_cache_match(dev, from);
cached = CACHE_OFFSET + entry * priv->cache.page_size + offset; cached = CACHE_OFFSET + entry * priv->cache.page_size + offset;
dev_dbg(priv->dev, "%s:%d: from=%08x cached=%08x offset=%08x " dev_dbg(&dev->core, "%s: from=%08x cached=%08x offset=%08x "
"avail=%08x count=%08x\n", __func__, __LINE__, "avail=%08x count=%08x\n", __func__,
(unsigned int)from, cached, offset, avail, count); (unsigned int)from, cached, offset, avail, count);
if (avail > count) if (avail > count)
...@@ -484,17 +473,17 @@ static int ps3vram_read(struct mtd_info *mtd, loff_t from, size_t len, ...@@ -484,17 +473,17 @@ static int ps3vram_read(struct mtd_info *mtd, loff_t from, size_t len,
return 0; return 0;
} }
static int ps3vram_write(struct mtd_info *mtd, loff_t to, size_t len, static int ps3vram_write(struct ps3_system_bus_device *dev, loff_t to,
size_t *retlen, const u_char *buf) size_t len, size_t *retlen, const u_char *buf)
{ {
struct ps3vram_priv *priv = mtd->priv; struct ps3vram_priv *priv = dev->core.driver_data;
unsigned int cached, count; unsigned int cached, count;
if (to >= mtd->size) if (to >= priv->size)
return -EINVAL; return -EIO;
if (len > mtd->size - to) if (len > priv->size - to)
len = mtd->size - to; len = priv->size - to;
/* Copy from buf to vram */ /* Copy from buf to vram */
count = len; count = len;
...@@ -507,12 +496,12 @@ static int ps3vram_write(struct mtd_info *mtd, loff_t to, size_t len, ...@@ -507,12 +496,12 @@ static int ps3vram_write(struct mtd_info *mtd, loff_t to, size_t len,
mutex_lock(&priv->lock); mutex_lock(&priv->lock);
entry = ps3vram_cache_match(mtd, to); entry = ps3vram_cache_match(dev, to);
cached = CACHE_OFFSET + entry * priv->cache.page_size + offset; cached = CACHE_OFFSET + entry * priv->cache.page_size + offset;
dev_dbg(priv->dev, "%s:%d: to=%08x cached=%08x offset=%08x " dev_dbg(&dev->core, "%s: to=%08x cached=%08x offset=%08x "
"avail=%08x count=%08x\n", __func__, __LINE__, "avail=%08x count=%08x\n", __func__, (unsigned int)to,
(unsigned int)to, cached, offset, avail, count); cached, offset, avail, count);
if (avail > count) if (avail > count)
avail = count; avail = count;
...@@ -531,36 +520,114 @@ static int ps3vram_write(struct mtd_info *mtd, loff_t to, size_t len, ...@@ -531,36 +520,114 @@ static int ps3vram_write(struct mtd_info *mtd, loff_t to, size_t len,
return 0; return 0;
} }
static int ps3vram_proc_show(struct seq_file *m, void *v)
{
struct ps3vram_priv *priv = m->private;
seq_printf(m, "hit:%u\nmiss:%u\n", priv->cache.hit, priv->cache.miss);
return 0;
}
static int ps3vram_proc_open(struct inode *inode, struct file *file)
{
return single_open(file, ps3vram_proc_show, PDE(inode)->data);
}
static const struct file_operations ps3vram_proc_fops = {
.owner = THIS_MODULE,
.open = ps3vram_proc_open,
.read = seq_read,
.llseek = seq_lseek,
.release = single_release,
};
static void __devinit ps3vram_proc_init(struct ps3_system_bus_device *dev)
{
struct ps3vram_priv *priv = dev->core.driver_data;
struct proc_dir_entry *pde;
pde = proc_create(DEVICE_NAME, 0444, NULL, &ps3vram_proc_fops);
if (!pde) {
dev_warn(&dev->core, "failed to create /proc entry\n");
return;
}
pde->owner = THIS_MODULE;
pde->data = priv;
}
static int ps3vram_make_request(struct request_queue *q, struct bio *bio)
{
struct ps3_system_bus_device *dev = q->queuedata;
int write = bio_data_dir(bio) == WRITE;
const char *op = write ? "write" : "read";
loff_t offset = bio->bi_sector << 9;
int error = 0;
struct bio_vec *bvec;
unsigned int i;
dev_dbg(&dev->core, "%s\n", __func__);
bio_for_each_segment(bvec, bio, i) {
/* PS3 is ppc64, so we don't handle highmem */
char *ptr = page_address(bvec->bv_page) + bvec->bv_offset;
size_t len = bvec->bv_len, retlen;
dev_dbg(&dev->core, " %s %zu bytes at offset %llu\n", op,
len, offset);
if (write)
error = ps3vram_write(dev, offset, len, &retlen, ptr);
else
error = ps3vram_read(dev, offset, len, &retlen, ptr);
if (error) {
dev_err(&dev->core, "%s failed\n", op);
goto out;
}
if (retlen != len) {
dev_err(&dev->core, "Short %s\n", op);
goto out;
}
offset += len;
}
dev_dbg(&dev->core, "%s completed\n", op);
out:
bio_endio(bio, error);
return 0;
}
static int __devinit ps3vram_probe(struct ps3_system_bus_device *dev) static int __devinit ps3vram_probe(struct ps3_system_bus_device *dev)
{ {
struct ps3vram_priv *priv; struct ps3vram_priv *priv;
int status; int error, status;
u64 ddr_lpar; struct request_queue *queue;
u64 ctrl_lpar; struct gendisk *gendisk;
u64 info_lpar; u64 ddr_lpar, ctrl_lpar, info_lpar, reports_lpar, ddr_size,
u64 reports_lpar; reports_size;
u64 ddr_size;
u64 reports_size;
int ret = -ENOMEM;
char *rest; char *rest;
ret = -EIO; priv = kzalloc(sizeof(*priv), GFP_KERNEL);
ps3vram_mtd.priv = kzalloc(sizeof(struct ps3vram_priv), GFP_KERNEL); if (!priv) {
if (!ps3vram_mtd.priv) error = -ENOMEM;
goto out; goto fail;
priv = ps3vram_mtd.priv; }
mutex_init(&priv->lock); mutex_init(&priv->lock);
priv->dev = &dev->core; dev->core.driver_data = priv;
priv = dev->core.driver_data;
/* Allocate XDR buffer (1MiB aligned) */ /* Allocate XDR buffer (1MiB aligned) */
priv->xdr_buf = (void *)__get_free_pages(GFP_KERNEL, priv->xdr_buf = (void *)__get_free_pages(GFP_KERNEL,
get_order(XDR_BUF_SIZE)); get_order(XDR_BUF_SIZE));
if (priv->xdr_buf == NULL) { if (priv->xdr_buf == NULL) {
dev_dbg(&dev->core, "%s:%d: could not allocate XDR buffer\n", dev_err(&dev->core, "Could not allocate XDR buffer\n");
__func__, __LINE__); error = -ENOMEM;
ret = -ENOMEM; goto fail_free_priv;
goto out_free_priv;
} }
/* Put FIFO at begginning of XDR buffer */ /* Put FIFO at begginning of XDR buffer */
...@@ -569,22 +636,17 @@ static int __devinit ps3vram_probe(struct ps3_system_bus_device *dev) ...@@ -569,22 +636,17 @@ static int __devinit ps3vram_probe(struct ps3_system_bus_device *dev)
/* XXX: Need to open GPU, in case ps3fb or snd_ps3 aren't loaded */ /* XXX: Need to open GPU, in case ps3fb or snd_ps3 aren't loaded */
if (ps3_open_hv_device(dev)) { if (ps3_open_hv_device(dev)) {
dev_err(&dev->core, "%s:%d: ps3_open_hv_device failed\n", dev_err(&dev->core, "ps3_open_hv_device failed\n");
__func__, __LINE__); error = -EAGAIN;
ret = -EAGAIN;
goto out_close_gpu; goto out_close_gpu;
} }
/* Request memory */ /* Request memory */
status = -1; status = -1;
ddr_size = memparse(size, &rest); ddr_size = ALIGN(memparse(size, &rest), 1024*1024);
if (*rest == '-') if (!ddr_size) {
ddr_size -= ps3fb_videomemory.size; dev_err(&dev->core, "Specified size is too small\n");
ddr_size = ALIGN(ddr_size, 1024*1024); error = -EINVAL;
if (ddr_size <= 0) {
dev_err(&dev->core, "%s:%d: specified size is too small\n",
__func__, __LINE__);
ret = -EINVAL;
goto out_close_gpu; goto out_close_gpu;
} }
...@@ -596,25 +658,22 @@ static int __devinit ps3vram_probe(struct ps3_system_bus_device *dev) ...@@ -596,25 +658,22 @@ static int __devinit ps3vram_probe(struct ps3_system_bus_device *dev)
break; break;
ddr_size -= 1024*1024; ddr_size -= 1024*1024;
} }
if (status || ddr_size <= 0) { if (status) {
dev_err(&dev->core, "%s:%d: lv1_gpu_memory_allocate failed\n", dev_err(&dev->core, "lv1_gpu_memory_allocate failed %d\n",
__func__, __LINE__); status);
ret = -ENOMEM; error = -ENOMEM;
goto out_free_xdr_buf; goto out_free_xdr_buf;
} }
/* Request context */ /* Request context */
status = lv1_gpu_context_allocate(priv->memory_handle, status = lv1_gpu_context_allocate(priv->memory_handle, 0,
0, &priv->context_handle, &ctrl_lpar,
&priv->context_handle, &info_lpar, &reports_lpar,
&ctrl_lpar,
&info_lpar,
&reports_lpar,
&reports_size); &reports_size);
if (status) { if (status) {
dev_err(&dev->core, "%s:%d: lv1_gpu_context_allocate failed\n", dev_err(&dev->core, "lv1_gpu_context_allocate failed %d\n",
__func__, __LINE__); status);
ret = -ENOMEM; error = -ENOMEM;
goto out_free_memory; goto out_free_memory;
} }
...@@ -623,82 +682,97 @@ static int __devinit ps3vram_probe(struct ps3_system_bus_device *dev) ...@@ -623,82 +682,97 @@ static int __devinit ps3vram_probe(struct ps3_system_bus_device *dev)
ps3_mm_phys_to_lpar(__pa(priv->xdr_buf)), ps3_mm_phys_to_lpar(__pa(priv->xdr_buf)),
XDR_BUF_SIZE, 0); XDR_BUF_SIZE, 0);
if (status) { if (status) {
dev_err(&dev->core, "%s:%d: lv1_gpu_context_iomap failed\n", dev_err(&dev->core, "lv1_gpu_context_iomap failed %d\n",
__func__, __LINE__); status);
ret = -ENOMEM; error = -ENOMEM;
goto out_free_context; goto out_free_context;
} }
priv->ddr_base = ioremap_flags(ddr_lpar, ddr_size, _PAGE_NO_CACHE); priv->ddr_base = ioremap_flags(ddr_lpar, ddr_size, _PAGE_NO_CACHE);
if (!priv->ddr_base) { if (!priv->ddr_base) {
dev_err(&dev->core, "%s:%d: ioremap failed\n", __func__, dev_err(&dev->core, "ioremap DDR failed\n");
__LINE__); error = -ENOMEM;
ret = -ENOMEM;
goto out_free_context; goto out_free_context;
} }
priv->ctrl = ioremap(ctrl_lpar, 64 * 1024); priv->ctrl = ioremap(ctrl_lpar, 64 * 1024);
if (!priv->ctrl) { if (!priv->ctrl) {
dev_err(&dev->core, "%s:%d: ioremap failed\n", __func__, dev_err(&dev->core, "ioremap CTRL failed\n");
__LINE__); error = -ENOMEM;
ret = -ENOMEM;
goto out_unmap_vram; goto out_unmap_vram;
} }
priv->reports = ioremap(reports_lpar, reports_size); priv->reports = ioremap(reports_lpar, reports_size);
if (!priv->reports) { if (!priv->reports) {
dev_err(&dev->core, "%s:%d: ioremap failed\n", __func__, dev_err(&dev->core, "ioremap REPORTS failed\n");
__LINE__); error = -ENOMEM;
ret = -ENOMEM;
goto out_unmap_ctrl; goto out_unmap_ctrl;
} }
mutex_lock(&ps3_gpu_mutex); mutex_lock(&ps3_gpu_mutex);
ps3vram_init_ring(&ps3vram_mtd); ps3vram_init_ring(dev);
mutex_unlock(&ps3_gpu_mutex); mutex_unlock(&ps3_gpu_mutex);
ps3vram_mtd.name = "ps3vram"; priv->size = ddr_size;
ps3vram_mtd.size = ddr_size;
ps3vram_mtd.flags = MTD_CAP_RAM; ps3vram_bind(dev);
ps3vram_mtd.erase = ps3vram_erase;
ps3vram_mtd.point = NULL;
ps3vram_mtd.unpoint = NULL;
ps3vram_mtd.read = ps3vram_read;
ps3vram_mtd.write = ps3vram_write;
ps3vram_mtd.owner = THIS_MODULE;
ps3vram_mtd.type = MTD_RAM;
ps3vram_mtd.erasesize = CACHE_PAGE_SIZE;
ps3vram_mtd.writesize = 1;
ps3vram_bind(&ps3vram_mtd);
mutex_lock(&ps3_gpu_mutex); mutex_lock(&ps3_gpu_mutex);
ret = ps3vram_wait_ring(&ps3vram_mtd, 100); error = ps3vram_wait_ring(dev, 100);
mutex_unlock(&ps3_gpu_mutex); mutex_unlock(&ps3_gpu_mutex);
if (ret < 0) { if (error < 0) {
dev_err(&dev->core, "%s:%d: failed to initialize channels\n", dev_err(&dev->core, "Failed to initialize channels\n");
__func__, __LINE__); error = -ETIMEDOUT;
ret = -ETIMEDOUT;
goto out_unmap_reports; goto out_unmap_reports;
} }
ps3vram_cache_init(&ps3vram_mtd); ps3vram_cache_init(dev);
ps3vram_proc_init(dev);
if (add_mtd_device(&ps3vram_mtd)) { queue = blk_alloc_queue(GFP_KERNEL);
dev_err(&dev->core, "%s:%d: add_mtd_device failed\n", if (!queue) {
__func__, __LINE__); dev_err(&dev->core, "blk_alloc_queue failed\n");
ret = -EAGAIN; error = -ENOMEM;
goto out_cache_cleanup; goto out_cache_cleanup;
} }
dev_info(&dev->core, "reserved %u MiB of gpu memory\n", priv->queue = queue;
(unsigned int)(ddr_size / 1024 / 1024)); queue->queuedata = dev;
blk_queue_make_request(queue, ps3vram_make_request);
blk_queue_max_phys_segments(queue, MAX_PHYS_SEGMENTS);
blk_queue_max_hw_segments(queue, MAX_HW_SEGMENTS);
blk_queue_max_segment_size(queue, MAX_SEGMENT_SIZE);
blk_queue_max_sectors(queue, SAFE_MAX_SECTORS);
gendisk = alloc_disk(1);
if (!gendisk) {
dev_err(&dev->core, "alloc_disk failed\n");
error = -ENOMEM;
goto fail_cleanup_queue;
}
priv->gendisk = gendisk;
gendisk->major = ps3vram_major;
gendisk->first_minor = 0;
gendisk->fops = &ps3vram_fops;
gendisk->queue = queue;
gendisk->private_data = dev;
gendisk->driverfs_dev = &dev->core;
strlcpy(gendisk->disk_name, DEVICE_NAME, sizeof(gendisk->disk_name));
set_capacity(gendisk, priv->size >> 9);
dev_info(&dev->core, "%s: Using %lu MiB of GPU memory\n",
gendisk->disk_name, get_capacity(gendisk) >> 11);
add_disk(gendisk);
return 0; return 0;
fail_cleanup_queue:
blk_cleanup_queue(queue);
out_cache_cleanup: out_cache_cleanup:
ps3vram_cache_cleanup(&ps3vram_mtd); remove_proc_entry(DEVICE_NAME, NULL);
ps3vram_cache_cleanup(dev);
out_unmap_reports: out_unmap_reports:
iounmap(priv->reports); iounmap(priv->reports);
out_unmap_ctrl: out_unmap_ctrl:
...@@ -713,21 +787,22 @@ static int __devinit ps3vram_probe(struct ps3_system_bus_device *dev) ...@@ -713,21 +787,22 @@ static int __devinit ps3vram_probe(struct ps3_system_bus_device *dev)
ps3_close_hv_device(dev); ps3_close_hv_device(dev);
out_free_xdr_buf: out_free_xdr_buf:
free_pages((unsigned long) priv->xdr_buf, get_order(XDR_BUF_SIZE)); free_pages((unsigned long) priv->xdr_buf, get_order(XDR_BUF_SIZE));
out_free_priv: fail_free_priv:
kfree(ps3vram_mtd.priv); kfree(priv);
ps3vram_mtd.priv = NULL; dev->core.driver_data = NULL;
out: fail:
return ret; return error;
} }
static int ps3vram_shutdown(struct ps3_system_bus_device *dev) static int ps3vram_remove(struct ps3_system_bus_device *dev)
{ {
struct ps3vram_priv *priv; struct ps3vram_priv *priv = dev->core.driver_data;
priv = ps3vram_mtd.priv;
del_mtd_device(&ps3vram_mtd); del_gendisk(priv->gendisk);
ps3vram_cache_cleanup(&ps3vram_mtd); put_disk(priv->gendisk);
blk_cleanup_queue(priv->queue);
remove_proc_entry(DEVICE_NAME, NULL);
ps3vram_cache_cleanup(dev);
iounmap(priv->reports); iounmap(priv->reports);
iounmap(priv->ctrl); iounmap(priv->ctrl);
iounmap(priv->ddr_base); iounmap(priv->ddr_base);
...@@ -736,33 +811,55 @@ static int ps3vram_shutdown(struct ps3_system_bus_device *dev) ...@@ -736,33 +811,55 @@ static int ps3vram_shutdown(struct ps3_system_bus_device *dev)
ps3_close_hv_device(dev); ps3_close_hv_device(dev);
free_pages((unsigned long) priv->xdr_buf, get_order(XDR_BUF_SIZE)); free_pages((unsigned long) priv->xdr_buf, get_order(XDR_BUF_SIZE));
kfree(priv); kfree(priv);
dev->core.driver_data = NULL;
return 0; return 0;
} }
static struct ps3_system_bus_driver ps3vram_driver = { static struct ps3_system_bus_driver ps3vram = {
.match_id = PS3_MATCH_ID_GPU, .match_id = PS3_MATCH_ID_GPU,
.match_sub_id = PS3_MATCH_SUB_ID_GPU_RAMDISK, .match_sub_id = PS3_MATCH_SUB_ID_GPU_RAMDISK,
.core.name = DEVICE_NAME, .core.name = DEVICE_NAME,
.core.owner = THIS_MODULE, .core.owner = THIS_MODULE,
.probe = ps3vram_probe, .probe = ps3vram_probe,
.remove = ps3vram_shutdown, .remove = ps3vram_remove,
.shutdown = ps3vram_shutdown, .shutdown = ps3vram_remove,
}; };
static int __init ps3vram_init(void) static int __init ps3vram_init(void)
{ {
return ps3_system_bus_driver_register(&ps3vram_driver); int error;
if (!firmware_has_feature(FW_FEATURE_PS3_LV1))
return -ENODEV;
error = register_blkdev(0, DEVICE_NAME);
if (error <= 0) {
pr_err("%s: register_blkdev failed %d\n", DEVICE_NAME, error);
return error;
}
ps3vram_major = error;
pr_info("%s: registered block device major %d\n", DEVICE_NAME,
ps3vram_major);
error = ps3_system_bus_driver_register(&ps3vram);
if (error)
unregister_blkdev(ps3vram_major, DEVICE_NAME);
return error;
} }
static void __exit ps3vram_exit(void) static void __exit ps3vram_exit(void)
{ {
ps3_system_bus_driver_unregister(&ps3vram_driver); ps3_system_bus_driver_unregister(&ps3vram);
unregister_blkdev(ps3vram_major, DEVICE_NAME);
} }
module_init(ps3vram_init); module_init(ps3vram_init);
module_exit(ps3vram_exit); module_exit(ps3vram_exit);
MODULE_LICENSE("GPL"); MODULE_LICENSE("GPL");
MODULE_AUTHOR("Jim Paris <jim@jtan.com>"); MODULE_DESCRIPTION("PS3 Video RAM Storage Driver");
MODULE_DESCRIPTION("MTD driver for PS3 video RAM"); MODULE_AUTHOR("Sony Corporation");
MODULE_ALIAS(PS3_MODULE_ALIAS_GPU_RAMDISK); MODULE_ALIAS(PS3_MODULE_ALIAS_GPU_RAMDISK);
...@@ -120,13 +120,6 @@ config MTD_PHRAM ...@@ -120,13 +120,6 @@ config MTD_PHRAM
doesn't have access to, memory beyond the mem=xxx limit, nvram, doesn't have access to, memory beyond the mem=xxx limit, nvram,
memory on the video card, etc... memory on the video card, etc...
config MTD_PS3VRAM
tristate "PS3 video RAM"
depends on FB_PS3
help
This driver allows you to use excess PS3 video RAM as volatile
storage or system swap.
config MTD_LART config MTD_LART
tristate "28F160xx flash driver for LART" tristate "28F160xx flash driver for LART"
depends on SA1100_LART depends on SA1100_LART
......
...@@ -16,4 +16,3 @@ obj-$(CONFIG_MTD_LART) += lart.o ...@@ -16,4 +16,3 @@ obj-$(CONFIG_MTD_LART) += lart.o
obj-$(CONFIG_MTD_BLOCK2MTD) += block2mtd.o obj-$(CONFIG_MTD_BLOCK2MTD) += block2mtd.o
obj-$(CONFIG_MTD_DATAFLASH) += mtd_dataflash.o obj-$(CONFIG_MTD_DATAFLASH) += mtd_dataflash.o
obj-$(CONFIG_MTD_M25P80) += m25p80.o obj-$(CONFIG_MTD_M25P80) += m25p80.o
obj-$(CONFIG_MTD_PS3VRAM) += ps3vram.o
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment