Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 989d5e92 authored by Abir Ghosh's avatar Abir Ghosh Committed by Gerrit - the friendly Code Review server
Browse files

soc: qcom: add support for fingerprint sensor driver



The QBT1000 driver provides an API for communicating
with trustzone applications and handles firmware event
interrupts.
The driver supports the following features:
 - loading and unloading trustzone applications.
 - sending commands to trustzone applications.
 - voting/un-voting for clocks before/after making
   a trustzone call.
 - receiving firmware events, signalled by interrupts,
   and providing them to the driver client.
 - sending a key event in response to firmware finger
   detect events.
 - support for multiple IPC messages.
 - retry logic for CBGE interrupt handling.
 - remove clocks on/off logic.

This is snapshot of the qbt1000 driver as of msm-4.4 kernel base
'd93c68b1f0bd (soc: qcom: add support for fingerprint sensor driver)' .

Change-Id: I59b4294285edab6e4916528a31d0713d06d5a072
Signed-off-by: default avatarAbir Ghosh <abirg@codeaurora.org>
parent d6686534
Loading
Loading
Loading
Loading
+54 −0
Original line number Diff line number Diff line
Qualcomm Technologies, Inc. QBT1000 Specific Bindings

QBT is a fingerprint sensor ASIC capable of performing fingerprint image scans
and detecting finger presence on the sensor using programmable firmware.

=======================
Required Node Structure
=======================

- compatible
  Usage:      required
  Value type: <string>
  Definition: "qcom,qbt1000".

- clock-names
  Usage:      required
  Value type: <stringlist>
  Definition: List of clock names that need to be voted on/off.

- clocks
  Usage:      required
  Value type: <prop_encoded-array>
  Definition: Property pair that represents the clock controller and the clock
		id. This in combination with the clock-name is used to obtain
		the handle for the clock that needs to be voted on/off.

- clock-frequency
  Usage:      required
  Value type: <u32>
  Definition: Frequency of clock in Hz.

- qcom,ipc-gpio
  Usage:      required
  Value type: <phandle>
  Definition: phandle for GPIO to be used for IPC.

- qcom,finger-detect-gpio
  Usage:      required
  Value type: <phandle>
  Definition: phandle for GPIO to be used for finger detect.

=======
Example
=======

qcom,qbt1000 {
	compatible = "qcom,qbt1000";
	clock-names = "core", "iface";
	clocks = <&clock_gcc clk_gcc_blsp2_qup6_spi_apps_clk>,
		<&clock_gcc clk_gcc_blsp2_ahb_clk>;
	clock-frequency = <15000000>;
	qcom,ipc-gpio = <&tlmm 121 0>;
	qcom,finger-detect-gpio = <&pmcobalt_gpios 2 0>;
};
+9 −0
Original line number Diff line number Diff line
@@ -616,6 +616,15 @@ config MSM_NOPM
	  This enables bare minimum support of power management at platform level.
	  i.e WFI

config MSM_QBT1000
	bool "QBT1000 Ultrasonic Fingerprint Sensor"
	help
	  This driver provides services for configuring the fingerprint
	  sensor hardware and for communicating with the trusted app which
	  uses it. It enables clocks and provides commands for loading
	  trusted apps, unloading them and marshalling buffers to the
	  trusted fingerprint app.

config APSS_CORE_EA
	depends on CPU_FREQ && PM_OPP
	bool "Qualcomm Technology Inc specific power aware driver"
+1 −0
Original line number Diff line number Diff line
@@ -65,6 +65,7 @@ ifdef CONFIG_MSM_SUBSYSTEM_RESTART
       obj-y += ramdump.o
endif
obj-$(CONFIG_QCOM_COMMAND_DB) += cmd-db.o
obj-$(CONFIG_MSM_QBT1000) += qbt1000.o
obj-$(CONFIG_WCD_DSP_GLINK) += wcd-dsp-glink.o
obj-$(CONFIG_MSM_EVENT_TIMER) += event_timer.o
obj-$(CONFIG_MSM_IDLE_STATS)	+= lpm-stats.o
+1207 −0

File added.

Preview size limit exceeded, changes collapsed.

+1 −0
Original line number Diff line number Diff line
@@ -382,6 +382,7 @@ header-y += prctl.h
header-y += psci.h
header-y += ptp_clock.h
header-y += ptrace.h
header-y += qbt1000.h
header-y += qcedev.h
header-y += qcota.h
header-y += qnx4_fs.h
Loading