|This will only work, if the Dlink 524 WiFi G router supports client mode.|
So the Dlink 524 will connect link an ordinary workstation. But in this case, all clients must be connected by wire to the 524.
If both routers supports WDS, both can be configured as an access point.
In that case, at the main router, you have to add the MAC address of the 524 in the WDS list.
On the 524 you have to add the MAC address of the Dlink 628 WiFi N.
SSID must be the same on both router as well as the encryption key.
The wireless network will not run on wireless N because the Dlink 524 doesn't support wireless N.