Vitamin D is really a hormone, has its own independent receptors and affects dozens of systems and tissues. Furthermore, deficiencies in Vitamin D are extremely common and can result in lowered testosterone levels. Correcting a deficiency can raise your testosterone by about 30% and make you feel a lot better with increased alertness and energy. (For the studies, see my link on Testosterone and Vitamin D.) One not-so-well-known property of Vitamin D is its ability to boost nitric oxide and endothelial function in some men. Below we'll quickly summarize some of the research showing this and just how Vitamin D works its magic.
Researchers began noticing that men (and women) with Vitamin D deficiencies had a host of symptoms that appeared to be related to decreased nitric oxide output: "hypertension, left ventricular hypertrophy, increased arterial stiffness, and endothelial dysfunction in normal subjects and in patients with chronic kidney disease and type 2 diabetes."  This was verified by a fairly recent animal study showing that Vitamin D deficient rats in the womb and early life were much more likely to develop hypertension and had a decreased ability to create nitric oxide.  A 2014 study on mice showed that mice that have a genetic defect that causes them to produce insufficient Vitamin D have a reduced expression of eNOS.  This is the enzyme that Viagra and Cialis affect and this explains why the animals have decreased nitric oxide and increased arterial stiffness.
Of course, us guys like nitric oxide due to its artery-expanding and erection-improving abilities. The goal is that as the arteries - penile or otherwise - expand, blood pressure is lowered and blood flow is increased. Vitamin D can actually positively influence both blood flow and blood pressure throught a completely different system: the kidneys. Vitamin D also includes "renoprotective effects and suppression of the renin angiotensin aldosterone system."  Animal studies back this up showing that lack of Vitamin D results in "elevated production of renin and angiotensin (Ang) II, leading to hypertension." 
Another important about Vitamin D is that it is likely to help protect your arteries from long term plaque buildup and hardening. This was shown in a study where Vitamin D levels were inversely correlated with coronary artery calcification.  A clinical application of this is the work of Dr. William Davis, who has stated that 25-hydroxy levels should be between 60 and 70 ng/ml to arrest or reverse arteriosclerosis. The 25-hydroxy test is the standard plasma test for Vitamin D levels and usually 30 ng/ml is considered a deficiency. Thus, Dr. Davis recommends about double the deficiency level, which seems both reasonable and cautious. (Too much Vitamin D can actually lead to calcification of the arteries.) And plaque buildup will only serve to decrease your natural endothelial nitric oxide levels. Arteries that are covered in plaque just don't secrete as much nitric oxide.
1) The Journal of Physiology, Oct 1 2011, 589:4777-4786, "Vitamin D insufficiency is associated with impaired vascular endothelial and smooth muscle function and hypertension in young rats"
2) Mol Endocrinol, 2014 Jan, 28(1):53-64, "Vitamin d is a regulator of endothelial nitric oxide synthase and arterial stiffness in mice"
3) Circulation, 1997, 96:1755-1760, "Active Serum Vitamin D Levels Are Inversely Correlated With Coronary Calcification"
4) Nature Reviews Cardiology, Oct 2009, 6:621-630, "Vitamin D status and arterial hypertension: a systematic review"
5) The Journal of Steroid Biochemistry and Molecular Biology, May 2004, 89-90:387 392, "Vitamin D: a negative endocrine regulator of the renin angiotensin system and blood pressure"