platform: msm: fix PFT char device major number

Dynamically allocate the major number
of the PFT character device.

Change-Id: I7877579781353203753f86a3993bc5731307db2a
Signed-off-by: Amir Samuelov <amirs@codeaurora.org>
Signed-off-by: franciscofranco <franciscofranco.1990@gmail.com>
platform: msm: pft: fix close all encrypted files

filp_close() eventually calls pft_file_close().
Simplify pft_close_opened_enc_files() and remove having mutex
in both places that cause a deadlock.

Change-Id: I0afa2d2f0806f18d430c027601fb9974855ef185
Signed-off-by: Amir Samuelov <amirs@codeaurora.org>
Signed-off-by: franciscofranco <franciscofranco.1990@gmail.com>
msm: cleanup and minor fixes for PFT driver

remove unused symlink hook.
free open-file-list on driver exit.
check return value of pft_add_file().

Change-Id: Ida1e4351742ae62cafb2ffa49727f490709351e2
Signed-off-by: Amir Samuelov <amirs@codeaurora.org>
Signed-off-by: franciscofranco <franciscofranco.1990@gmail.com>
platform: msm: fix PFT when using direct-io

When we read/write a file using dircet-io (O_DIRECT),
we can't get the inode from a bio by walking the path
bio->bi_io_vec->bv_page->mapping->host
since the page is anonymous and not mapped.
On the other more typical cases when not using O_DIRECT,
the page cache is used and the bv_page is available.

Change-Id: I349cad54a978ed9919f960d55f0f95c1e53262e5
Signed-off-by: Amir Samuelov <amirs@codeaurora.org>
Signed-off-by: franciscofranco <franciscofranco.1990@gmail.com>
security: selinux: Add Per-File-Encryption hooks

Add hooks for tagging/detecting Per-File-Encryption files.

Change-Id: I9d1f791b68d3552b1a508c21ff8336182e8527fa
Signed-off-by: Amir Samuelov <amirs@codeaurora.org>
Signed-off-by: franciscofranco <franciscofranco.1990@gmail.com>
ARM: dts: msm: Remove bus active-only property from TSPP

TSPP HW blocks would use the PNOC bus independent
of the power collapse state of the CPU. Making bus vote
with active-only will cause the vote to be removed by
RPM when CPU gets into power collapse state.

CRs-Fixed: 546090
Change-Id: Ia3963f84f96eb96747867d28a8b09889de8ca22f
Signed-off-by: Hamad Kadmany <hkadmany@codeaurora.org>
Signed-off-by: franciscofranco <franciscofranco.1990@gmail.com>