11 Understanding binder and classification

Understanding binder and classification

1. What is binder?

  • binder is a communication mechanism

    Binder is a kind of IPC communication, IPC: Inter-Process Communication (Inter-Process Communication)

    Commonly used inter-process communication in Android includes shared memory, pipeline, signal processing, sockect, binder, etc.;

    Commonly used between the kernel and user space is a shared memory mechanism;

    Some low data transfers are handled using sockect

    The transfer between application processes uses the Binder mechanism

  • binder is a virtual physical device driver

    The bottom layer of binder is actually a driver device, and the driver device corresponding to Android 8.0: /dev/binder

    Then there is also a daemon process: /system/bin/serviceManager

    A binder library: /system/lib64/lib

    After android8.0, the Treble mechanism was introduced, mainly to facilitate the rapid porting, upgrading, and improving system stability of the Android system.

    The binder driver device is expanded to: /dev/binder; dev/hwbinder; dev/vndbinder

    /dev/binder: Proprietary node for Android interprocess communication

    /dev/hwbinder: The provider's access node, and needs to convert AIDL to HIDL

    /dev/vndbinder: If you want to continue to use AIDL between vendor processes, you need to use dev/vndbinder instead of dev/binder

    IPC域 illustrate

Guess you like

Origin blog.csdn.net/Johnny2004/article/details/130857569