Is there any problem in checking PHP PDO connection this manner?
I'm not quite sure I see the purpose of this function.

It essentially checks if a PDO connection is possible.  It does not actually return a connection.  In addition to that, it has hard coded credentials, thus killing all flexibility.  Also, there's no evident reason why you made it MySQL specific.  None of your options used are MySQL specific.

Since a boolean is returned, if( $pdo_mysql = pdo_mysql() ) is redundant too:

if (pdo_mysql()) is sufficient (unless you plan on using the true/false $pdo_mysql outside of the if/else block).

You should pass the credentials into the function instead of hard coding them.  Once you've done that though, you've kind of removed any need for the function.

Personally, I don't see a purpose for this function.  Just make the connection without this function.  If you want to keep it in some kind of centralized place, just keep in it a simple bootstrap file, or even a simple bootstrapping class.  



I've been vague on basically everything in this post, so if you want more detail, let me know :).



Also, I might have missed the point of your function.  Is your end goal to connect to a MySQL server, or to check if you could connect to a MySQL server?