The Sprint Planning Meeting is the initial event in which all the Scrum Team takes part. It is usually time-boxed to 8 hours for a Sprint event that lasts a month. This duration is proportional to the Sprint’s one. If the Sprint is planned for half month, the Sprint Planning Meeting will have a time-box of 4 hours and so on. This initial meeting is divided in two parts, each one is time-boxed with 4 hours, proportional in case of a reduction in the Sprint duration.
What will be done?
In this part the Development Team predicts what will they be able to do during the Sprint, the product owner presents the Product Backlog items and all the Scrum Team collaborate together to understand them, after that, the Development Team (only them) select the Product Backlog items. This item selection will form the Sprint Backlog. In addition, the Scrum Team figures out and create the Sprint Goal.
How will the chosen work get done?
Here the Development Team tries to decompose the work to be done to units of one day or less. If they believe that there is too much or too less work to do, they may renegotiate the work load with the Product Owner. It is important to say that in this subphase only the Development Team is obliged to participate, but the Scrum Master can support the process and the Product Owner may be present to clarify the Product Backlog’s items.
Source: Scrum Guide and my summaries about it.