Trying to lock users out is doomed to fail. Many solutions would have a "snooze button" effect where people might be more distracted by the additional effort to get around the lock. Others might end up being far too restrictive (what about passengers? people in buses or trains? people in emergency situations?).
Technology is also only a small part of distracted driving. It's still perfectly legal for me to eat a Big Mac and fries while having a heated debate with passengers and adjusting the car stereo while driving. We ought to build (1) a culture that strongly discourages this, and (2) cars that build in safety features (driver alertness detection, etc) while reducing the attention requirements of the driver (automatic collision avoidance, self-driving cars...)