Skip to content
Permalink
Browse files

Revert to 3.0.8/jellybean kernel

  • Loading branch information
Dazzozo committed Jan 24, 2013
1 parent 86d7e6e commit 0538d7bc8ceb39f7cace39bcb1892bb3446298e7
@@ -3,7 +3,6 @@ USE_CAMERA_STUB := false
-include vendor/huawei/u8815/BoardConfigVendor.mk

# CPU and Platform
TARGET_ARCH := arm
TARGET_BOARD_PLATFORM := msm7x27a
TARGET_BOARD_PLATFORM_GPU := qcom-adreno200

@@ -31,8 +30,7 @@ TARGET_USE_SPARROW_BIONIC_OPTIMIZATION := true
TARGET_AVOID_DRAW_TEXTURE_EXTENSION := true
TARGET_USES_16BPPSURFACE_FOR_OPAQUE := true

TARGET_USES_ION := true
BOARD_HAVE_OLD_ION_API := true
TARGET_USES_ION := false

TARGET_BOOTLOADER_BOARD_NAME := u8815
TARGET_OTA_ASSERT_DEVICE := u8815,hwu8815,u8818,hwu8818
@@ -65,7 +63,8 @@ BOARD_ADRENO_DECIDE_TEXTURE_TARGET := true
BOARD_AVOID_DRAW_TEXTURE_EXTENSION := true
BOARD_USE_SKIA_LCDTEXT := true
TARGET_NO_HW_OVERLAY := true
TARGET_QCOM_DISPLAY_VARIANT := caf
TARGET_QCOM_DISPLAY_VARIANT := legacy
BOARD_EGL_NEEDS_LEGACY_FB := true

# Video
COMMON_GLOBAL_CFLAGS += -DQCOM_ICS_DECODERS -DQCOM_NO_SECURE_PLAYBACK
@@ -52,14 +52,6 @@ enum ion_heap_type {
#define ION_HEAP_CARVEOUT_MASK (1 << ION_HEAP_TYPE_CARVEOUT)
#define ION_HEAP_CP_MASK (1 << ION_HEAP_TYPE_CP)

/**
* heap flags - the lower 16 bits are used by core ion, the upper 16
* bits are reserved for use by the heaps themselves.
*/
#define ION_FLAG_CACHED 1 /* mappings of this buffer should be
cached, ion will do cache
maintenance when the buffer is
mapped for dma */

/**
* These are the only ids that should be used for Ion heap ids.
@@ -72,19 +64,12 @@ enum ion_heap_type {

enum ion_heap_ids {
INVALID_HEAP_ID = -1,
/* In a system with the "Mini Ion Upgrade" (such as this one)
* the heap_mask and caching flag end up sharing a spot in
* ion_allocation_data.flags. We should make sure to never use
* the 0th bit for a heap because that's where the caching bit
* ends up.
*/
ION_BOGUS_HEAP_DO_NOT_USE = 0,
ION_IOMMU_HEAP_ID = 4,
ION_CP_MM_HEAP_ID = 8,
ION_CP_MFC_HEAP_ID = 12,
ION_CP_WB_HEAP_ID = 16, /* 8660 only */
ION_CAMERA_HEAP_ID = 20, /* 8660 only */
ION_SF_HEAP_ID = 24,
ION_IOMMU_HEAP_ID = 25,
ION_QSECOM_HEAP_ID = 27,
ION_AUDIO_HEAP_ID = 28,

@@ -102,14 +87,6 @@ enum ion_heap_ids {
};

#define ION_KMALLOC_HEAP_NAME "kmalloc"

enum ion_fixed_position {
NOT_FIXED,
FIXED_LOW,
FIXED_MIDDLE,
FIXED_HIGH,
};

/**
* Flag to use when allocating to indicate that a heap is secure.
*/
@@ -141,12 +118,6 @@ enum ion_fixed_position {

#define ION_IS_CACHED(__flags) ((__flags) & (1 << ION_CACHE_SHIFT))

/*
* This flag allows clients when mapping into the IOMMU to specify to
* defer un-mapping from the IOMMU until the buffer memory is freed.
*/
#define ION_IOMMU_UNMAP_DELAYED 1

#ifdef __KERNEL__
#include <linux/err.h>
#include <mach/ion.h>
@@ -172,7 +143,6 @@ struct ion_buffer;
* @base: base address of heap in physical memory if applicable
* @size: size of the heap in bytes if applicable
* @memory_type:Memory type used for the heap
* @has_outer_cache: set to 1 if outer cache is used, 0 otherwise.
* @extra_data: Extra data specific to each heap type
*/
struct ion_platform_heap {
@@ -182,7 +152,6 @@ struct ion_platform_heap {
ion_phys_addr_t base;
size_t size;
enum ion_memory_types memory_type;
unsigned int has_outer_cache;
void *extra_data;
};

@@ -199,12 +168,7 @@ struct ion_platform_heap {
* of this heap in the case of a shared heap.
* @reusable Flag indicating whether this heap is reusable of not.
* (see FMEM)
* @mem_is_fmem Flag indicating whether this memory is coming from fmem
* or not.
* @fixed_position If nonzero, position in the fixed area.
* @virt_addr: Virtual address used when using fmem.
* @iommu_map_all: Indicates whether we should map whole heap into IOMMU.
* @iommu_2x_map_domain: Indicates the domain to use for overmapping.
* @request_region: function to be called when the number of allocations
* goes from 0 -> 1
* @release_region: function to be called when the number of allocations
@@ -218,10 +182,6 @@ struct ion_cp_heap_pdata {
ion_phys_addr_t secure_base; /* Base addr used when heap is shared */
size_t secure_size; /* Size used for securing heap when heap is shared*/
int reusable;
int mem_is_fmem;
enum ion_fixed_position fixed_position;
int iommu_map_all;
int iommu_2x_map_domain;
ion_virt_addr_t *virt_addr;
int (*request_region)(void *);
int (*release_region)(void *);
@@ -232,9 +192,6 @@ struct ion_cp_heap_pdata {
* struct ion_co_heap_pdata - defines a carveout heap in the given platform
* @adjacent_mem_id: Id of heap that this heap must be adjacent to.
* @align: Alignment requirement for the memory
* @mem_is_fmem Flag indicating whether this memory is coming from fmem
* or not.
* @fixed_position If nonzero, position in the fixed area.
* @request_region: function to be called when the number of allocations
* goes from 0 -> 1
* @release_region: function to be called when the number of allocations
@@ -245,16 +202,13 @@ struct ion_cp_heap_pdata {
struct ion_co_heap_pdata {
int adjacent_mem_id;
unsigned int align;
int mem_is_fmem;
enum ion_fixed_position fixed_position;
int (*request_region)(void *);
int (*release_region)(void *);
void *(*setup_region)(void);
};

/**
* struct ion_platform_data - array of platform heaps passed from board file
* @has_outer_cache: set to 1 if outer cache is used, 0 otherwise.
* @nr: number of structures in the array
* @request_region: function to be called when the number of allocations goes
* from 0 -> 1
@@ -266,7 +220,6 @@ struct ion_co_heap_pdata {
* Provided by the board file in the form of platform data to a platform device.
*/
struct ion_platform_data {
unsigned int has_outer_cache;
int nr;
int (*request_region)(void *);
int (*release_region)(void *);
@@ -456,7 +409,6 @@ int ion_handle_get_flags(struct ion_client *client, struct ion_handle *handle,
* @iova - pointer to store the iova address
* @buffer_size - pointer to store the size of the buffer
* @flags - flags for options to map
* @iommu_flags - flags specific to the iommu.
*
* Maps the handle into the iova space specified via domain number. Iova
* will be allocated from the partition specified via partition_num.
@@ -466,7 +418,7 @@ int ion_map_iommu(struct ion_client *client, struct ion_handle *handle,
int domain_num, int partition_num, unsigned long align,
unsigned long iova_length, unsigned long *iova,
unsigned long *buffer_size,
unsigned long flags, unsigned long iommu_flags);
unsigned long flags);


/**
@@ -543,23 +495,6 @@ int msm_ion_secure_heap(int heap_id);
*/
int msm_ion_unsecure_heap(int heap_id);

/**
* msm_ion_do_cache_op - do cache operations.
*
* @client - pointer to ION client.
* @handle - pointer to buffer handle.
* @vaddr - virtual address to operate on.
* @len - Length of data to do cache operation on.
* @cmd - Cache operation to perform:
* ION_IOC_CLEAN_CACHES
* ION_IOC_INV_CACHES
* ION_IOC_CLEAN_INV_CACHES
*
* Returns 0 on success
*/
int msm_ion_do_cache_op(struct ion_client *client, struct ion_handle *handle,
void *vaddr, unsigned long len, unsigned int cmd);

#else
static inline struct ion_client *ion_client_create(struct ion_device *dev,
unsigned int heap_mask, const char *name)
@@ -637,9 +572,7 @@ static inline int ion_map_iommu(struct ion_client *client,
struct ion_handle *handle, int domain_num,
int partition_num, unsigned long align,
unsigned long iova_length, unsigned long *iova,
unsigned long *buffer_size,
unsigned long flags,
unsigned long iommu_flags)
unsigned long flags)
{
return -ENODEV;
}
@@ -672,14 +605,6 @@ static inline int msm_ion_unsecure_heap(int heap_id)
{
return -ENODEV;
}

static inline int msm_ion_do_cache_op(struct ion_client *client,
struct ion_handle *handle, void *vaddr,
unsigned long len, unsigned int cmd)
{
return -ENODEV;
}

#endif /* CONFIG_ION */
#endif /* __KERNEL__ */

@@ -704,7 +629,6 @@ static inline int msm_ion_do_cache_op(struct ion_client *client,
struct ion_allocation_data {
size_t len;
size_t align;
unsigned int heap_mask;
unsigned int flags;
struct ion_handle *handle;
};
@@ -825,7 +749,7 @@ struct ion_flag_data {
* descriptor obtained from ION_IOC_SHARE and returns the struct with the handle
* filed set to the corresponding opaque handle.
*/
#define ION_IOC_IMPORT _IOWR(ION_IOC_MAGIC, 5, struct ion_fd_data)
#define ION_IOC_IMPORT _IOWR(ION_IOC_MAGIC, 5, int)

/**
* DOC: ION_IOC_CUSTOM - call architecture specific ion ioctl
@@ -841,21 +765,21 @@ struct ion_flag_data {
*
* Clean the caches of the handle specified.
*/
#define ION_IOC_CLEAN_CACHES _IOWR(ION_IOC_MAGIC, 20, \
#define ION_IOC_CLEAN_CACHES _IOWR(ION_IOC_MAGIC, 7, \
struct ion_flush_data)
/**
* DOC: ION_MSM_IOC_INV_CACHES - invalidate the caches
*
* Invalidate the caches of the handle specified.
*/
#define ION_IOC_INV_CACHES _IOWR(ION_IOC_MAGIC, 21, \
#define ION_IOC_INV_CACHES _IOWR(ION_IOC_MAGIC, 8, \
struct ion_flush_data)
/**
* DOC: ION_MSM_IOC_CLEAN_CACHES - clean and invalidate the caches
*
* Clean and invalidate the caches of the handle specified.
*/
#define ION_IOC_CLEAN_INV_CACHES _IOWR(ION_IOC_MAGIC, 22, \
#define ION_IOC_CLEAN_INV_CACHES _IOWR(ION_IOC_MAGIC, 9, \
struct ion_flush_data)

/**
@@ -864,15 +788,6 @@ struct ion_flag_data {
* Gets the flags of the current handle which indicate cachability,
* secure state etc.
*/
#define ION_IOC_GET_FLAGS _IOWR(ION_IOC_MAGIC, 23, \
struct ion_flag_data)


/**
* DOC: ION_IOC_SYNC - BOGUS
*
* NOT SUPPORTED
*/
#define ION_IOC_SYNC _IOWR(ION_IOC_MAGIC, 42, \
#define ION_IOC_GET_FLAGS _IOWR(ION_IOC_MAGIC, 10, \
struct ion_flag_data)
#endif /* _LINUX_ION_H */

0 comments on commit 0538d7b

Please sign in to comment.
You can’t perform that action at this time.