[PATCH 5/6 v6] kvm: booke: clear host tlb reference flag on guest tlb invalidation

2013-09-19 Thread Bharat Bhushan
On booke, "struct tlbe_ref" contains host tlb mapping information (pfn: for guest-pfn to pfn, flags: attribute associated with this mapping) for a guest tlb entry. So when a guest creates a TLB entry then "struct tlbe_ref" is set to point to valid "pfn" and set attributes in "flags" field of the ab

RE: [PATCH 5/6 v5] kvm: booke: clear host tlb reference flag on guest tlb invalidation

2013-09-19 Thread Bhushan Bharat-R65777
> -Original Message- > From: Wood Scott-B07421 > Sent: Friday, September 20, 2013 2:38 AM > To: Bhushan Bharat-R65777 > Cc: b...@kernel.crashing.org; ag...@suse.de; pau...@samba.org; > k...@vger.kernel.org; kvm-...@vger.kernel.org; linuxppc-dev@lists.ozlabs.org; > Bhushan Bharat-R65777 >

Re: [PATCH 1/2][v3] powerpc/fsl-booke: Add initial T104x_QDS board support

2013-09-19 Thread Timur Tabi
Kushwaha Prabhakar-B32579 wrote: My primary object is to put base patch in Linux. once it done other things can be enabled one by one. Any features which are not enabled must be specified in the patch description. The patch says that the board supports DIU, but the code doesn't, so that's m

[PATCH 08/51] DMA-API: net: intel/ixgbevf: fix 32-bit DMA mask handling

2013-09-19 Thread Russell King
The fallback to 32-bit DMA mask is rather odd: if (!dma_set_mask(&pdev->dev, DMA_BIT_MASK(64)) && !dma_set_coherent_mask(&pdev->dev, DMA_BIT_MASK(64))) { pci_using_dac = 1; } else { err = dma_set_mask(&pdev->dev, DMA_BIT_MASK(32));

[PATCH 07/51] DMA-API: net: intel/ixgbe: fix 32-bit DMA mask handling

2013-09-19 Thread Russell King
The fallback to 32-bit DMA mask is rather odd: if (!dma_set_mask(&pdev->dev, DMA_BIT_MASK(64)) && !dma_set_coherent_mask(&pdev->dev, DMA_BIT_MASK(64))) { pci_using_dac = 1; } else { err = dma_set_mask(&pdev->dev, DMA_BIT_MASK(32));

[PATCH 01/51] DMA-API: provide a helper to set both DMA and coherent DMA masks

2013-09-19 Thread Russell King
Provide a helper to set both the DMA and coherent DMA masks to the same value - this avoids duplicated code in a number of drivers, sometimes with buggy error handling, and also allows us identify which drivers do things differently. Signed-off-by: Russell King --- Documentation/DMA-API-HOWTO.tx

[PATCH 05/51] DMA-API: net: intel/igbvf: fix 32-bit DMA mask handling

2013-09-19 Thread Russell King
The fallback to 32-bit DMA mask is rather odd: err = dma_set_mask(&pdev->dev, DMA_BIT_MASK(64)); if (!err) { err = dma_set_coherent_mask(&pdev->dev, DMA_BIT_MASK(64)); if (!err) pci_using_dac = 1; } else {

[PATCH 02/51] DMA-API: net: brocade/bna/bnad.c: fix 32-bit DMA mask handling

2013-09-19 Thread Russell King
The fallback to 32-bit DMA mask is rather odd: if (!dma_set_mask(&pdev->dev, DMA_BIT_MASK(64)) && !dma_set_coherent_mask(&pdev->dev, DMA_BIT_MASK(64))) { *using_dac = true; } else { err = dma_set_mask(&pdev->dev, DMA_BIT_MASK(32));

[PATCH 06/51] DMA-API: net: intel/ixgb: fix 32-bit DMA mask handling

2013-09-19 Thread Russell King
The fallback to 32-bit DMA mask is rather odd: err = dma_set_mask(&pdev->dev, DMA_BIT_MASK(64)); if (!err) { err = dma_set_coherent_mask(&pdev->dev, DMA_BIT_MASK(64)); if (!err) pci_using_dac = 1; } else {

[PATCH 03/51] DMA-API: net: intel/e1000e: fix 32-bit DMA mask handling

2013-09-19 Thread Russell King
The fallback to 32-bit DMA mask is rather odd: err = dma_set_mask(&pdev->dev, DMA_BIT_MASK(64)); if (!err) { err = dma_set_coherent_mask(&pdev->dev, DMA_BIT_MASK(64)); if (!err) pci_using_dac = 1; } else {

[PATCH 04/51] DMA-API: net: intel/igb: fix 32-bit DMA mask handling

2013-09-19 Thread Russell King
The fallback to 32-bit DMA mask is rather odd: err = dma_set_mask(&pdev->dev, DMA_BIT_MASK(64)); if (!err) { err = dma_set_coherent_mask(&pdev->dev, DMA_BIT_MASK(64)); if (!err) pci_using_dac = 1; } else {

RE: [PATCH 1/2][v3] powerpc/fsl-booke: Add initial T104x_QDS board support

2013-09-19 Thread Kushwaha Prabhakar-B32579
Hi Tabi, > -Original Message- > From: Timur Tabi [mailto:ti...@tabi.org] > Sent: Friday, September 20, 2013 2:03 AM > To: Kushwaha Prabhakar-B32579 > Cc: linuxppc-dev@lists.ozlabs.org; Wood Scott-B07421; Jain Priyanka- > B32167; Aggrwal Poonam-B10812 > Subject: Re: [PATCH 1/2][v3] powerpc/

Re: [PATCH 01/51] DMA-API: provide a helper to set both DMA and coherent DMA masks

2013-09-19 Thread Ben Hutchings
On Thu, 2013-09-19 at 22:25 +0100, Russell King wrote: > Provide a helper to set both the DMA and coherent DMA masks to the > same value - this avoids duplicated code in a number of drivers, > sometimes with buggy error handling, and also allows us identify > which drivers do things differently. >

Re: Preliminary kexec support for Linux/m68k

2013-09-19 Thread Simon Horman
On Thu, Sep 19, 2013 at 11:20:22AM +0200, Geert Uytterhoeven wrote: > On Tue, Sep 17, 2013 at 12:01 PM, Geert Uytterhoeven > wrote: > > This is a preliminary set of patches to add kexec support for m68k. > > > - [PATCH 1/3] m68k: Add preliminary kexec support > > - [PATCH 2/3] m68k: Add suppo

[PATCH 00/51] DMA mask changes

2013-09-19 Thread Russell King - ARM Linux
This started out as a request to look at the DMA mask situation, and how to solve the issues which we have on ARM - notably how the DMA mask should be setup. However, I started off reviewing how the dma_mask and coherent_dma_mask was being used, and what I found was rather messy, and in some cases

Re: [PATCH 5/6 v5] kvm: booke: clear host tlb reference flag on guest tlb invalidation

2013-09-19 Thread Scott Wood
On Thu, 2013-09-19 at 11:32 +0530, Bharat Bhushan wrote: > On booke, "struct tlbe_ref" contains host tlb mapping information > (pfn: for guest-pfn to pfn, flags: attribute associated with this mapping) > for a guest tlb entry. So when a guest creates a TLB entry then > "struct tlbe_ref" is set to p

Re: [PATCH 1/2][v3] powerpc/fsl-booke: Add initial T104x_QDS board support

2013-09-19 Thread Timur Tabi
On Thu, Sep 19, 2013 at 4:00 AM, Prabhakar Kushwaha wrote: > - Video > - DIU supports video at up to 1280x1024x32bpp You mention DIU support, except there's no DIU enablement in the platform file. You need the T104x equivalent of p1022ds_set_pixel_clock() and the other functions.

Does iommu_init_table need to use GFP_ATOMIC allocations?

2013-09-19 Thread Nishanth Aravamudan
Under heavy (DLPAR?) stress, we tripped this panic() in arch/powerpc/kernel/iommu.c::iommu_init_table(): page = alloc_pages_node(nid, GFP_ATOMIC, get_order(sz)); if (!page) panic("iommu_init_table: Can't allocate %ld bytes\n", sz); Before the panic() we got a page

Re: Preliminary kexec support for Linux/m68k

2013-09-19 Thread Geert Uytterhoeven
On Tue, Sep 17, 2013 at 12:01 PM, Geert Uytterhoeven wrote: > This is a preliminary set of patches to add kexec support for m68k. > - [PATCH 1/3] m68k: Add preliminary kexec support > - [PATCH 2/3] m68k: Add support to export bootinfo in procfs > - [PATCH 3/3] [RFC] m68k: Add System RAM to

[PATCH 2/2][v3] powerpc/configs: Enable T1040QDS by default in corenet

2013-09-19 Thread Prabhakar Kushwaha
T1040 supports both 32 & 64 bit kernel. so enable T1040QDS by default in the config files. Signed-off-by: Prabhakar Kushwaha --- Based upon git://git.kernel.org/pub/scm/linux/kernel/git/benh/powerpc.git Branch next Changes for v2: Sending as it is Changes for v3: Sending as it is a

[PATCH 1/2][v3] powerpc/fsl-booke: Add initial T104x_QDS board support

2013-09-19 Thread Prabhakar Kushwaha
Add support for T104x board in board file t104x_qds.c, It is common for both T1040 and T1042 as they share same QDS board. T1040QDS board Overview --- - SERDES Connections, 8 lanes supporting: — PCI Express: supporting Gen 1 and Gen 2; — SGMII — QSGMII

[PATCH][v3] powerpc/mpc85xx:Add initial device tree support of T104x

2013-09-19 Thread Prabhakar Kushwaha
The QorIQ T1040/T1042 processor support four integrated 64-bit e5500 PA processor cores with high-performance data path acceleration architecture and network peripheral interfaces required for networking & telecommunications. T1042 personality is a reduced personality of T1040 without Integrated 8

Re: [PATCH 8/8][v4] powerpc/perf: Export Power7 memory hierarchy info to user space.

2013-09-19 Thread Anshuman Khandual
On 09/14/2013 06:19 AM, Sukadev Bhattiprolu wrote: > +static void power7_get_mem_data_src(union perf_mem_data_src *dsrc, > + struct pt_regs *regs) > +{ > + u64 idx; > + u64 mmcra = regs->dsisr; > + u64 addr; > + int ret; > + unsigned int instr; > + > + if

[PATCH 7/7] vfio pci: Add vfio iommu implementation for FSL_PAMU

2013-09-19 Thread Bharat Bhushan
This patch adds vfio iommu support for Freescale IOMMU (PAMU - Peripheral Access Management Unit). The Freescale PAMU is an aperture-based IOMMU with the following characteristics. Each device has an entry in a table in memory describing the iova->phys mapping. The mapping has: -an overall aper

[PATCH 6/7] vfio: moving some functions in common file

2013-09-19 Thread Bharat Bhushan
Some function defined in vfio_iommu_type1.c were common and we want to use these for FSL IOMMU (PAMU) and iommu-none driver. So some of them are moved to vfio_iommu_common.c I think we can do more of that but we will take this step by step. Signed-off-by: Bharat Bhushan --- drivers/vfio/Makefil

[PATCH 4/7] powerpc: translate msi addr to iova if iommu is in use

2013-09-19 Thread Bharat Bhushan
If the device is attached with iommu domain then set MSI address to the iova configured in PAMU. Signed-off-by: Bharat Bhushan --- arch/powerpc/sysdev/fsl_msi.c | 56 +++- 1 files changed, 54 insertions(+), 2 deletions(-) diff --git a/arch/powerpc/sysdev/fs

[PATCH 5/7] iommu: supress loff_t compilation error on powerpc

2013-09-19 Thread Bharat Bhushan
Signed-off-by: Bharat Bhushan --- drivers/vfio/pci/vfio_pci_rdwr.c |3 ++- 1 files changed, 2 insertions(+), 1 deletions(-) diff --git a/drivers/vfio/pci/vfio_pci_rdwr.c b/drivers/vfio/pci/vfio_pci_rdwr.c index 210db24..8a8156a 100644 --- a/drivers/vfio/pci/vfio_pci_rdwr.c +++ b/drivers/vfio

[PATCH 0/7] vfio-pci: add support for Freescale IOMMU (PAMU)

2013-09-19 Thread Bharat Bhushan
From: Bharat Bhushan This patchset adds support for vfio-pci with Freescale IOMMU (PAMU- Peripheral Access Management Unit) The Freescale PAMU is an aperture-based IOMMU with the following characteristics. Each device has an entry in a table in memory describing the iova->phys mapping. The mapp

[PATCH 3/7] fsl iommu: add get_dev_iommu_domain

2013-09-19 Thread Bharat Bhushan
From: Bharat Bhushan returns the iommu_domain of the requested device for fsl pamu. Use PCI controller dev struct for pci devices as current LIODN schema assign LIODN to PCI controller not PCI device. This will be corrected with proper LIODN schema. Signed-off-by: Bharat Bhushan --- drivers/i

[PATCH 2/7] iommu: add api to get iommu_domain of a device

2013-09-19 Thread Bharat Bhushan
This api return the iommu domain to which the device is attached. The iommu_domain is required for making API calls related to iommu. Follow up patches which use this API to know iommu maping. Signed-off-by: Bharat Bhushan --- drivers/iommu/iommu.c | 10 ++ include/linux/iommu.h |7

[PATCH 1/7] powerpc: Add interface to get msi region information

2013-09-19 Thread Bharat Bhushan
This patch adds interface to get following information - Number of MSI regions (which is number of MSI banks for powerpc). - Get the region address range: Physical page which have the address/addresses used for generating MSI interrupt and size of the page. These are required to crea