If you are in the dark world, you can use your mirror anywhere to get back to the light world.
If you are stuck in the light world and can't get back to the little sparkly spot to return to the dark world, you will need to find a portal. There are several scattered around the map. I know there is one near the Tower of Hera, one north of Kakariko (if you have a hammer), another one in the north part of the swamp area (again, if you have a hammer)... there are several others but I don't remember them all. ZD has a guide of the warps here:
http://www.zeldadungeon.net/Zelda03-a-link-to-the-past-warps.php
Alternatively, die, save and quit, and restart your file. You'll be given a choice where to start if you were in the light world (Sanctuary or Link's house) or you will start on the top of the pyramid if you were in the dark world.
http://www.zeldadungeon.net/Zelda03-a-link-to-the-past-warps.php