OneWire - Fast pin mode defines

Ok, I took a shot at getting this library up and running: https://github.com/balbano/OneWire-Photon

The relevant snippet is:

  #elif PLATFORM_ID == 6 // Photon
    STM32_Pin_Info* PIN_MAP = HAL_Pin_Map(); // Pointer required for highest access speed

    inline void digitalWriteFastLow() {
      PIN_MAP[_pin].gpio_peripheral->BSRRH = PIN_MAP[_pin].gpio_pin;
    }

    inline void digitalWriteFastHigh() {
      PIN_MAP[_pin].gpio_peripheral->BSRRL = PIN_MAP[_pin].gpio_pin;
    }

    inline void pinModeFastOutput(void){
      // This could probably be speed up by digging a little deeper past
      // the HAL_Pin_Mode function.
      HAL_Pin_Mode(_pin, OUTPUT);
    }

    inline void pinModeFastInput(void){
      // This could probably be speed up by digging a little deeper past
      // the HAL_Pin_Mode function.
      HAL_Pin_Mode(_pin, INPUT);
    }

    inline uint8_t digitalReadFast(void){
      // This could probably be speed up by digging a little deeper past
      // the HAL_GPIO_Read function.
      return HAL_GPIO_Read(_pin);
    }

Not sure if this is the best way to do this, but it seems to work for me.