stm32: f4: Add FLASH_OPTCR1 definition

This is required for stm32f42xx and stm32f43xx with second bank options.
[ETH] Phy ID configurable as parameter
[ETH] Make support of ethernet for F1 family
[fix] after phyid addition, the init function should init correct phy.
ethernet: mac stm32fxx7: Fix style and docs

Rushed commits are bad mkay :)
[STM32F0] add support of autotrimming HSI to USB SOF frames

Signed-off-by: Frantisek Burian <BuFran@seznam.cz>
[STM32F0] Add support functions for USB clock setup in F072 chips.

There is remaining an issue with PREDIV connected just after clock multiplexer (only F072). This should be fixed in another commit.
usb: Prevent memcpy() being called with NULL arguments

If there is no additional iface data then iface->extra is NULL and
iface->extralen is zero. Passing NULL to memcpy is undefined behaviour
even if the length of data to copy is zero. In other words a conforming
(debug) memcpy implementation is permitted to assert(dst && src) without
checking the value of n.

Add an extra branch to avoid this.
usb: Support for class specific endpoint descriptors.

Extends struct usb_endpoint_descriptor to make it possible to provide
the USB host with class-specific extensions to endpoint descriptors.

The approach taken, based on extra and extralen and removing the sizeof()
from USB_DT_ENDPOINT_SIZE, is identical to the approach used to add
class-specific extensions to interface descriptors. All libopencm3-examples
use the USB_DT_ENDPOINT_SIZE (rather than directly using sizeof) so there
should be no compatibility problems resulting from this change.
usb: Support for MIDI class devices

Provides all of the config descriptors for MIDI class devices together
with a sub-set of the audio class sufficient to put together a full
fledged MIDI device.
stm32: f4: flash: support extended sector ranges

F42xx and F43xx have extended sector ranges.

Reported-by: H2OBrain@irc
[usb] fix user_callback_set_config

USB using control callbacks was broken since d6bad27735a77b8daa90ce72b843cf08ba78697d
Properly check if user usb control callback are registered,
while here make sure user_callback_set_config callback pointers are initialized to NULL.
stm32: f1: fix missing ahb_freq