Skip to content

Commit

Permalink
Move NFC/eSE settings
Browse files Browse the repository at this point in the history
Bug: 196825539
Test: build pass
Change-Id: I590f069139f641d886e1252e3acdb19483b7fcaa
  • Loading branch information
George Chang committed Aug 18, 2021
1 parent cd9ea62 commit 8933f1b
Show file tree
Hide file tree
Showing 11 changed files with 121 additions and 8 deletions.
5 changes: 5 additions & 0 deletions conf/init.raviole.rc
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
# Raven/Oriole specific init.rc

on init
# NFC streset tool name
setprop persist.vendor.nfc.streset libstreset21
setprop persist.vendor.se.streset libstreset21

on init && property:ro.vendor.factory=1
import /vendor/etc/init/hw/init.factory.rc

Expand Down
5 changes: 5 additions & 0 deletions conf/init.slider.rc
Original file line number Diff line number Diff line change
@@ -1,6 +1,11 @@
# Slider specific init.rc
import /vendor/etc/init/hw/init.gs101.rc

on init
# NFC streset tool name
setprop persist.vendor.nfc.streset libstreset21
setprop persist.vendor.se.streset libstreset21

# When ro.build.flavor=factory_slider-userdebug, add vendor/bin/factory to default path
on init && property:ro.build.flavor=factory_slider-userdebug
import /vendor/etc/init/hw/init.factory.rc
Expand Down
5 changes: 5 additions & 0 deletions conf/init.whitefin.rc
Original file line number Diff line number Diff line change
@@ -1,6 +1,11 @@
# Whitefin specific init.rc
import /vendor/etc/init/hw/init.gs101.rc

on init
# NFC streset tool name
setprop persist.vendor.nfc.streset libstreset21
setprop persist.vendor.se.streset libstreset21

on init && property:ro.build.flavor=factory_whitefin-userdebug
import /vendor/etc/init/hw/init.factory.rc

Expand Down
22 changes: 21 additions & 1 deletion device-oriole.mk
Original file line number Diff line number Diff line change
Expand Up @@ -91,12 +91,32 @@ PRODUCT_COPY_FILES += \

# NFC
PRODUCT_COPY_FILES += \
frameworks/native/data/etc/android.hardware.nfc.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.nfc.xml \
frameworks/native/data/etc/android.hardware.nfc.hce.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.nfc.hce.xml \
frameworks/native/data/etc/android.hardware.nfc.hcef.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.nfc.hcef.xml \
frameworks/native/data/etc/com.nxp.mifare.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/com.nxp.mifare.xml \
frameworks/native/data/etc/android.hardware.nfc.uicc.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.nfc.uicc.xml \
frameworks/native/data/etc/android.hardware.nfc.ese.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.nfc.ese.xml \
device/google/raviole/nfc/libnfc-hal-st.conf:$(TARGET_COPY_OUT_VENDOR)/etc/libnfc-hal-st.conf \
device/google/raviole/nfc/libnfc-nci.conf:$(TARGET_COPY_OUT_PRODUCT)/etc/libnfc-nci.conf

PRODUCT_PACKAGES += \
NfcNci \
Tag \
[email protected]

# SecureElement
PRODUCT_PACKAGES += \
[email protected]

PRODUCT_COPY_FILES += \
frameworks/native/data/etc/android.hardware.se.omapi.ese.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.se.omapi.ese.xml \
frameworks/native/data/etc/android.hardware.se.omapi.uicc.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.se.omapi.uicc.xml \
device/google/raviole/nfc/libse-gto-hal.conf:$(TARGET_COPY_OUT_VENDOR)/etc/libse-gto-hal.conf

DEVICE_MANIFEST_FILE += \
device/google/gs101/nfc/manifest_se_gs101.xml
device/google/raviole/nfc/manifest_nfc.xml \
device/google/raviole/nfc/manifest_se.xml

# Vibrator HAL
PRODUCT_PRODUCT_PROPERTIES +=\
Expand Down
23 changes: 22 additions & 1 deletion device-raven.mk
Original file line number Diff line number Diff line change
Expand Up @@ -94,11 +94,32 @@ PRODUCT_DEFAULT_PROPERTY_OVERRIDES += vendor.display.brightness.dimming.usage=2

# NFC
PRODUCT_COPY_FILES += \
frameworks/native/data/etc/android.hardware.nfc.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.nfc.xml \
frameworks/native/data/etc/android.hardware.nfc.hce.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.nfc.hce.xml \
frameworks/native/data/etc/android.hardware.nfc.hcef.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.nfc.hcef.xml \
frameworks/native/data/etc/com.nxp.mifare.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/com.nxp.mifare.xml \
frameworks/native/data/etc/android.hardware.nfc.uicc.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.nfc.uicc.xml \
frameworks/native/data/etc/android.hardware.nfc.ese.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.nfc.ese.xml \
device/google/raviole/nfc/libnfc-hal-st.conf:$(TARGET_COPY_OUT_VENDOR)/etc/libnfc-hal-st.conf \
device/google/raviole/nfc/libnfc-nci-raven.conf:$(TARGET_COPY_OUT_PRODUCT)/etc/libnfc-nci.conf

PRODUCT_PACKAGES += \
NfcNci \
Tag \
[email protected]

# SecureElement
PRODUCT_PACKAGES += \
[email protected]

PRODUCT_COPY_FILES += \
frameworks/native/data/etc/android.hardware.se.omapi.ese.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.se.omapi.ese.xml \
frameworks/native/data/etc/android.hardware.se.omapi.uicc.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.se.omapi.uicc.xml \
device/google/raviole/nfc/libse-gto-hal.conf:$(TARGET_COPY_OUT_VENDOR)/etc/libse-gto-hal.conf

DEVICE_MANIFEST_FILE += \
device/google/gs101/nfc/manifest_se_gs101.xml
device/google/raviole/nfc/manifest_nfc.xml \
device/google/raviole/nfc/manifest_se.xml

# Vibrator HAL
PRODUCT_PRODUCT_PROPERTIES +=\
Expand Down
30 changes: 25 additions & 5 deletions device-slider.mk
Original file line number Diff line number Diff line change
Expand Up @@ -57,20 +57,40 @@ PRODUCT_PROPERTY_OVERRIDES += \

# SecureElement
PRODUCT_PACKAGES += \
[email protected] \
[email protected]
[email protected]

PRODUCT_COPY_FILES += \
device/google/gs101/nfc/libse-gto-hal.conf:$(TARGET_COPY_OUT_VENDOR)/etc/libse-gto-hal.conf \
device/google/gs101/nfc/libse-gto-hal2.conf:$(TARGET_COPY_OUT_VENDOR)/etc/libse-gto-hal2.conf
device/google/raviole/nfc/libse-gto-hal.conf:$(TARGET_COPY_OUT_VENDOR)/etc/libse-gto-hal.conf

# NFC
PRODUCT_COPY_FILES += \
frameworks/native/data/etc/android.hardware.nfc.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.nfc.xml \
frameworks/native/data/etc/android.hardware.nfc.hce.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.nfc.hce.xml \
frameworks/native/data/etc/android.hardware.nfc.hcef.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.nfc.hcef.xml \
frameworks/native/data/etc/com.nxp.mifare.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/com.nxp.mifare.xml \
frameworks/native/data/etc/android.hardware.nfc.uicc.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.nfc.uicc.xml \
frameworks/native/data/etc/android.hardware.nfc.ese.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.nfc.ese.xml \
device/google/raviole/nfc/libnfc-hal-st-disable.conf:$(TARGET_COPY_OUT_VENDOR)/etc/libnfc-hal-st.conf \
device/google/raviole/nfc/libnfc-nci.conf:$(TARGET_COPY_OUT_PRODUCT)/etc/libnfc-nci.conf

PRODUCT_PACKAGES += \
NfcNci \
Tag \
[email protected]

# SecureElement
PRODUCT_PACKAGES += \
[email protected]

PRODUCT_COPY_FILES += \
frameworks/native/data/etc/android.hardware.se.omapi.ese.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.se.omapi.ese.xml \
frameworks/native/data/etc/android.hardware.se.omapi.uicc.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.se.omapi.uicc.xml \
device/google/raviole/nfc/libse-gto-hal.conf:$(TARGET_COPY_OUT_VENDOR)/etc/libse-gto-hal.conf \
device/google/raviole/nfc/libse-gto-hal2.conf:$(TARGET_COPY_OUT_VENDOR)/etc/libse-gto-hal2.conf

DEVICE_MANIFEST_FILE += \
device/google/gs101/nfc/manifest_se_gs101.xml
device/google/raviole/nfc/manifest_nfc.xml \
device/google/raviole/nfc/manifest_se.xml

# PowerStats HAL
PRODUCT_SOONG_NAMESPACES += device/google/raviole/powerstats/slider
Expand Down
17 changes: 16 additions & 1 deletion device-whitefin.mk
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,22 @@ PRODUCT_PRODUCT_PROPERTIES += \

# NFC
PRODUCT_COPY_FILES += \
device/google/gs101/nfc/libnfc-hal-st.conf:$(TARGET_COPY_OUT_VENDOR)/etc/libnfc-hal-st.conf
frameworks/native/data/etc/android.hardware.nfc.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.nfc.xml \
frameworks/native/data/etc/android.hardware.nfc.hce.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.nfc.hce.xml \
frameworks/native/data/etc/android.hardware.nfc.hcef.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.nfc.hcef.xml \
frameworks/native/data/etc/com.nxp.mifare.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/com.nxp.mifare.xml \
frameworks/native/data/etc/android.hardware.nfc.uicc.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.nfc.uicc.xml \
frameworks/native/data/etc/android.hardware.se.omapi.uicc.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.se.omapi.uicc.xml \
device/google/raviole/nfc/libnfc-hal-st.conf:$(TARGET_COPY_OUT_VENDOR)/etc/libnfc-hal-st.conf \
device/google/raviole/nfc/libnfc-nci.conf:$(TARGET_COPY_OUT_PRODUCT)/etc/libnfc-nci.conf

PRODUCT_PACKAGES += \
NfcNci \
Tag \
[email protected]

DEVICE_MANIFEST_FILE += \
device/google/raviole/nfc/manifest_nfc.xml

# PowerStats HAL
PRODUCT_SOONG_NAMESPACES += device/google/raviole/powerstats/whitefin
Expand Down
2 changes: 2 additions & 0 deletions nfc/libse-gto-hal.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
#Gemalto SPI devnode
GTO_DEV=/dev/st54spi;
2 changes: 2 additions & 0 deletions nfc/libse-gto-hal2.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
#Gemalto SPI devnode
GTO_DEV=/dev/st33spi;
11 changes: 11 additions & 0 deletions nfc/manifest_nfc.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
<manifest version="1.0" type="device">
<hal format="hidl">
<name>android.hardware.nfc</name>
<transport>hwbinder</transport>
<version>1.2</version>
<interface>
<name>INfc</name>
<instance>default</instance>
</interface>
</hal>
</manifest>
7 changes: 7 additions & 0 deletions nfc/manifest_se.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
<manifest version="1.0" type="device">
<hal format="hidl">
<name>android.hardware.secure_element</name>
<transport>hwbinder</transport>
<fqname>@1.2::ISecureElement/eSE1</fqname>
</hal>
</manifest>

0 comments on commit 8933f1b

Please sign in to comment.