The law says visas cannot be denied due to race, nationality or place of birth and if Trumps motives were really national defense he'd be banning The Sunnis from Saudi Arabia rather than Shiites from Iran.
Actually no law says that. There have been many times in Americans history where visas have been denied based on race, nationality, or place of birth. All of this has been held up in court. It is likely that Trump's executive order (like those from Presidents before him) involving bans of travelers from particular countries will be upheld in the Supreme Court.